This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Possible g77 bug
- From: Mats Peterson <mats at snowbee dot dyns dot cx>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 20 Dec 2002 02:31:50 +0100 (CET)
- Subject: Possible g77 bug
Hello.
The code below doesn't work with g77 in either FreeBSD or Linux.
Try pressing Control-D and watch it loop forever.
It does work with the Compaq Fortran compiler.
g77 version: GNU Fortran 0.5.25 20010315 (release)
FreeBSD version: 4.6.2-RELEASE-p5
Linux version: 2.4.18
---------------------------------------------------------
PROGRAM TEST
10 READ (UNIT=*, FMT=*, IOSTAT=NERR, ERR=100) N
PRINT *, 'You entered ', N
GO TO 10
100 IF (NERR .LT. 0) THEN
PRINT *, 'EOF'
STOP
ENDIF
PRINT *, 'Invalid input'
GO TO 10
END
---------------------------------------------------------
Regards,
Mats Peterson