Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!auspex!guy From: guy@auspex.auspex.com (Guy Harris) Newsgroups: comp.sys.sgi Subject: Re: Mixing ANSI and K & R 1 code. Message-ID: <4414@auspex.auspex.com> Date: 16 Nov 90 19:28:26 GMT References: <9011140836.AA17405@karron.med.nyu.edu> Organization: Auspex Systems, Santa Clara Lines: 22 >Seems you can't have newstyle argument lists (ANSI) receiving parameters >from old styles,non prototyped code. > >I first tried to write all my new stuff in ANSI code, but it would >always get float (Coord) arguments wrong. ... >This is something that should be fixed. Fine, hop in your time machine, go back to the ANSI C meetings where they decided that if you have a routine declared with prototypes with arguments that are "float", that it really gets passed "float"s, not "double"s, and convince them otherwise. That should fix it.... If that's not possible, you're out of luck unless you can convince SGI or whoever to have "float" just mean "double", which is unlikely given the number of other things it'll probably break.... If you have a routine that is to have prototypes, is to be passed floating-point arguments, and is to be called by old-style C, make its arguments "double" - even if that means not giving them type "Coord".