4 ! Functions shall not have an initializer.
6 ! Due to -fwhole-file, the function declaration
7 ! warnings come before the init warnings; thus
8 ! the warning for the WRONG lines have been moved to
13 integer :: f1
= 42 ! WRONG, see func_decl_5.f90
16 function f2() RESULT (r
)
17 integer :: r
= 42 ! WRONG, see func_decl_5.f90
20 function f3() RESULT (f3
) ! { dg-error "must be different than function name" }
22 end function ! { dg-error "Expecting END PROGRAM" }
23 ! { dg-error "Unexpected end of file" "" { target "*-*-*" } 0 }