2 ! { dg-options "-fcheck=recursion" }
3 ! { dg-shouldfail "Recursion check" }
6 ! Recursion run-time check
9 subroutine NormalFunc()
10 end subroutine NormalFunc
12 recursive subroutine valid(x
)
20 end subroutine sndValid
24 if(x
) call sndInvalid()
27 end subroutine invalid
29 subroutine sndInvalid()
31 end subroutine sndInvalid
40 ! { dg-output "Fortran runtime error: Recursive call to nonrecursive procedure 'invalid'" }