public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/35584]  New: invalid warning: branch causes infinite loop
@ 2008-03-14 16:03 dfranke at gcc dot gnu dot org
  2008-03-14 16:05 ` [Bug fortran/35584] " dfranke at gcc dot gnu dot org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: dfranke at gcc dot gnu dot org @ 2008-03-14 16:03 UTC (permalink / raw)
  To: gcc-bugs

Extracted from a FORTRAN 77 application:

$> cat infloop.f
      open (5, file = 't2.txt')
      do while (.TRUE.)
1       read(5,*,err=1,end=2) i
        write(*,*) i
      enddo

2     close(5)
      end

$> gfortran-svn -g -Wall -W infloop.f
infloop.f:3.72:

1       read(5,*,err=1,end=2) i
                                                                       1
Warning: Branch at (1) causes an infinite loop


This is not exactly true. Consider:

$> cat t2.txt
2
a
3

$> ./a.out t2.txt
           2
           3


-- 
           Summary: invalid warning: branch causes infinite loop
           Product: gcc
           Version: 4.4.0
            Status: UNCONFIRMED
          Keywords: diagnostic
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dfranke at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35584


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2008-03-15 14:35 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-03-14 16:03 [Bug fortran/35584] New: invalid warning: branch causes infinite loop dfranke at gcc dot gnu dot org
2008-03-14 16:05 ` [Bug fortran/35584] " dfranke at gcc dot gnu dot org
2008-03-15  0:29 ` dfranke at gcc dot gnu dot org
2008-03-15  0:34 ` [Bug fortran/35584] overzealous " dfranke at gcc dot gnu dot org
2008-03-15  7:10 ` jvdelisle at gcc dot gnu dot org
2008-03-15 14:30 ` dfranke at gcc dot gnu dot org
2008-03-15 14:35 ` dfranke at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).