2 ! { dg-options "-Werror -O3" }
4 ! Tests the fix for PR78619, in which the recursive use of 'f' at line 13
7 ! Contributed by Gerhard Steinmetz <gerhard.steinmetz.fortran@t-online.de>
9 print *, g(1.0) ! 'g' is OK
11 function f(x
) result(z
)
13 z
= sign(1.0, f
) ! { dg-error "calling itself recursively|must be the same type" }
18 g
= -sign(1.0, g
) ! This is OK.
21 ! { dg-message "all warnings being treated as errors" "" { target *-*-* } 0 }