Path: utzoo!attcan!uunet!lll-winken!lll-tis!helios.ee.lbl.gov!pasteur!agate!ucbvax!decwrl!purdue!bu-cs!bloom-beacon!tut.cis.ohio-state.edu!accelerator.eng.ohio-state.edu!kaa.eng.ohio-state.edu!rob From: rob@kaa.eng.ohio-state.edu (Rob Carriere) Newsgroups: comp.std.c Subject: Re: nonportable code or incorrect compilers? Message-ID: <376@accelerator.eng.ohio-state.edu> Date: 10 Jul 88 00:09:10 GMT References: <133@daitc.ARPA> <430@uwovax.uwo.ca> <374@accelerator.eng.ohio-state.edu> <8228@brl-smoke.ARPA> Sender: news@accelerator.eng.ohio-state.edu Reply-To: rob@kaa.eng.ohio-state.edu (Rob Carriere) Organization: Ohio State Univ, College of Engineering Lines: 15 In article <8228@brl-smoke.ARPA> gwyn@brl.arpa (Doug Gwyn (VLD/VMB)) writes: >In article <374@accelerator.eng.ohio-state.edu> rob@raksha.eng.ohio-state.edu >(Rob Carriere) writes: [...] >>Sounds like the type cast is not going to be done => 800 is right. >I didn't see any cast operator. If you mean type conversion, >one IS supposed to be done in order to evaluate a*b where a is >an int and b is a double. Then the assignment to a should >truncate the double expression value back to an int. Whoops. You didn't see it because it isn't there, I *did* mean conversion. However, the conversion rule says that a is to be converted to double; this seems to contradict the idea that a is to be computed *once*. Rob Carriere