2 ! { dg-options "-fwhole-file" }
3 ! Test the fixes for the first two problems in PR40011
5 ! Contributed by Dominique d'Humieres <dominiq@lps.ens.fr>
7 ! This function would not compile because -fwhole-file would
8 ! try repeatedly to resolve the function because of the self
10 RECURSIVE FUNCTION eval_args(q
) result (r
)
12 PARAMETER (NNODE
= 10)
18 TYPE(NODE
) heap(NNODE
)
20 r
= eval_args(heap(q
)%cdr
)
21 END FUNCTION eval_args
24 real, dimension(2) :: test
30 program arr
! The error was not picked up causing an ICE
31 real, dimension(2) :: res
32 res
= test(2) ! { dg-error "Explicit interface required" }