Different warning with *.f and *.f90 suffix (was Compilation and run of the FDS code)
Steve Kargl
sgk@troutmask.apl.washington.edu
Tue Apr 18 20:39:00 GMT 2006
On Tue, Apr 18, 2006 at 10:13:09PM +0200, Dominique Dhumieres wrote:
> I have now at least a partial understanding of what happened with
> the warnings. I have reduced it to:
>
> [karma] f90/bug% cat read_bndf_1.f90
> SUBROUTINE READ_BNDF
> !
> CHARACTER(30) QUANTITY
> NAMELIST /BNDF/ DTSAM,QUANTITY,FYI
> !
> BNDFLOOP: DO N=1,NBF
> READ(LU5,BNDF,END=243,ERR=244)
>
> SEARCH: DO ND=-NDATA,NDATA
> ENDDO SEARCH
>
> 244 ENDDO BNDFLOOP
> 243 REWIND(LU5)
>
> END SUBROUTINE READ_BNDF
>
> Then I get:
>
> [karma] f90/bug% gfortran -c read_bndf_1.f90
> In file read_bndf_1.f90:7
>
> READ(LU5,BNDF,END=243,ERR=244)
> 1
> In file read_bndf_1.f90:12
>
> 244 ENDDO BNDFLOOP
> 2
> Warning: Obsolete: GOTO at (1) jumps to END of construct at (2)
> [karma] f90/bug% cp read_bndf_1.f90 read_bndf_1.f
> [karma] f90/bug% gfortran -c read_bndf_1.f
> In file read_bndf_1.f:7
>
> READ(LU5,BNDF,END=243,ERR=244)
> 1
> In file read_bndf_1.f:12
>
>
> 2
> Warning: Obsolete: GOTO at (1) jumps to END of construct at (2)
>
> So the warning is at it should be with the f90 suffix, but not with the
> f one. Note that the 'SEARCH' do loop is required to get the warning
> for reasons I don't understand.
I don't understand your comment about the 'SEARCH' loop.
--
Steve
More information about the Fortran
mailing list