Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!apple!sun-barr!newstop!sun!khb From: khb@chiba.Eng.Sun.COM (Keith Bierman - SPD Advanced Languages) Newsgroups: comp.sys.mips Subject: Re: f77 bug Message-ID: Date: 29 Mar 90 02:44:43 GMT References: <1990Mar28.133559.20912@sobeco.com> Sender: news@sun.Eng.Sun.COM Organization: Sun MegaSystems Lines: 42 In-reply-to: laporte@sobeco.com's message of 28 Mar 90 13:35:59 GMT In article <1990Mar28.133559.20912@sobeco.com> laporte@sobeco.com (p.laporte) writes: .... bad code gives the following results i= 4 f= 4.0000000E-07 d= 4.0000000000000004E-16 Of course the results for f and d re wrong. Is this fixed in version 2.10 of the compiler ? I suggest that you reread section 13 of x3.9-1978 again. The implied . is not where you think it is. If you write the code as character*10 mot double precision d real f mot = '4, ' read(mot,*) i write(*,*) 'i=',i read(mot,*) f write(*,*) 'f=',f read(mot,*) d write(*,*) 'd=',d end I think you will be much happier with the results. -- Keith H. Bierman |*My thoughts are my own. !! kbierman@Eng.Sun.COM It's Not My Fault | MTS --Only my work belongs to Sun* kbierman%eng@sun.com I Voted for Bill & | Advanced Languages/Floating Point Group Opus | "When the going gets Weird .. the Weird turn PRO"