[Bug fortran/61069] Gfortran allows functions to be called as subroutines when defined in a separate source file

2014-05-06 Thread tristanmoody at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=61069 --- Comment #9 from Tristan Moody --- (In reply to Steve Kargl from comment #8) > program foo > integer i > external bar, baz > i=0 > call bar(i) > call baz(i) > end > > This is standard conforming Fortran. When gfortran compiles

[Bug fortran/61069] Gfortran allows functions to be called as subroutines when defined in a separate source file

2014-05-06 Thread tristanmoody at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=61069 --- Comment #7 from Tristan Moody --- (In reply to Steve Kargl from comment #5) > The Fortran code conforms to the Fortran standard! Why do you continue to > claim that it is nonconforming invalid code. What the linker does to > the object code

[Bug fortran/61069] Gfortran allows functions to be called as subroutines when defined in a separate source file

2014-05-05 Thread tristanmoody at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=61069 --- Comment #2 from Tristan Moody --- Of course the code is invalid. That's the point. The compiler is inconsistent about whether it will catch that fact. This invalid code could easily show up, say, when refactoring a large code base, converting

[Bug fortran/61069] New: Gfortran allows functions to be called as subroutines when defined in a separate source file

2014-05-05 Thread tristanmoody at gmail dot com
Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: tristanmoody at gmail dot com This might not be the easiest thing to fix, as (1) it appears that verifying the semantics of a function call happen on a per