Path: utzoo!attcan!uunet!nih-csl!lhc!mimsy!midway!linac!pacific.mps.ohio-state.edu!zaphod.mps.ohio-state.edu!rpi!uupsi!sunic!ericom!etxsj23.ericsson.se!etxpnil From: etxpnil@etxsj23.ericsson.se (Per Nilsson TT/SJG 98194 ) Newsgroups: comp.sys.amiga Subject: Lattice C double Message-ID: <1990Sep28.063045.2599@ericsson.se> Date: 28 Sep 90 06:30:45 GMT Sender: news@ericsson.se Organization: Ericsson Telecom, Stockholm, Sweden Lines: 23 The following is a test program I've compiled with the Lattice C compiler. main() { double dub; dub = 12345678.0; dub = dub * 10.0; printf("%.9g\n",dub); } When compiled with the Lattice C V5.04, I've got the following output: 123456779.999999999 On my SPARC station I got the correct result: 123456780 Is this some kind of bug in the Lattice C compiler ? Is there any way around this problem ?