home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / sys / sgi / 12666 < prev    next >
Encoding:
Internet Message Format  |  1992-08-20  |  892 b 

  1. Path: sparky!uunet!dove!cam!blue
  2. From: blue@cam.nist.gov (Jim Blue)
  3. Newsgroups: comp.sys.sgi
  4. Subject: Fortran error, 4.0.1
  5. Message-ID: <9818@fs3.cam.nist.gov>
  6. Date: 20 Aug 92 14:41:13 GMT
  7. Sender: news@cam.nist.gov
  8. Organization: National Institute of Standards and Technology, Gaithersburg, MD
  9. Lines: 24
  10.  
  11. The following simple program illustrates a bug in Fortran under Irix 4.0.1.
  12. Isn't the implied do loop supposed to be legal?
  13.  
  14.       integer ires(9, 9)
  15.       integer diag(9)
  16.       do 100 j = 1, 9
  17.          do 100 k = 1, 9
  18.             ires(j, k) = 10 * j + k
  19.   100 continue
  20.       write(*, 999) (ires(j,j), j = 1, 9)
  21.       do 200 j = 1, 9
  22.          diag(j) = ires(j, j)
  23.   200 continue
  24.       write(*, 999) (diag(j), j = 1, 9)
  25.   999 format(9i4)
  26.       stop
  27.       end
  28.  
  29. ----- The above is in junk.f -----
  30.  
  31. >f77 junk.f
  32. >a.out
  33.   10  10   0   0   0   0   0****   0
  34.   11  22  33  44  55  66  77  88  99
  35.