Path: utzoo!attcan!uunet!husc6!mailrus!uwmcsd1!ig!agate!ucbvax!CORY.BERKELEY.EDU!dillon From: dillon@CORY.BERKELEY.EDU (Matt Dillon) Newsgroups: comp.sys.amiga.tech Subject: Re: Manxifying Lattice Code Message-ID: <8808061912.AA02369@cory.Berkeley.EDU> Date: 6 Aug 88 19:12:07 GMT Sender: daemon@ucbvax.BERKELEY.EDU Lines: 15 >Also, Stuart mentioned he was compiling with +L. Doesn't that mean that >Manx will use longs for ints rather than shorts? And if so, doesn't THAT >mean that "sizeof(tplanet)" will be a long? So, the question is: what will >malloc() do when you pass it a long and it wants a short? Assuming you LINK with the proper library (c32.lib), malloc WANTS a long. > pplant = (tplanet *) malloc((short)sizeof(tplanet)); The compiler would promptly expand sizeof() backup to a long after chopping the high 16 bits and pass a long. (assuming you are compiling with +L) -Matt