[EMAIL PROTECTED]:~/src> cat t.f90
subroutine a
call f(g)
contains
function g(x)
x =0.
end function g
end subroutine a
[EMAIL PROTECTED]:~/src> gcc/build/gcc/f951 -quiet t.f90
t.f90: In function 'g':
t.f90:5: warning: Function return value not set
[EMAIL PROTECTED]:~/src>
This is not allowed, as can be understood by considering what happens if a
variable of the containing function's scope is referenced.
--
Summary: allows passing of contained subprograms as actual
argument
Product: gcc
Version: 4.2.0
Status: UNCONFIRMED
Keywords: accepts-invalid
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: tobi at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25034