Merge from mainline (165734:167278).
[official-gcc/graphite-test-results.git] / gcc / testsuite / gfortran.dg / proc_ptr_12.f90
blob325703f499d5833c2a239ecf62203b0b708f26d2
1 ! { dg-do run }
3 ! PR 36704: Procedure pointer as function result
5 ! Contributed by Janus Weil <janus@gcc.gnu.org>
7 procedure(integer),pointer :: p
8 p => foo()
9 if (p(-1)/=1) call abort
10 contains
11 function foo() result(bar)
12 procedure(integer),pointer :: bar
13 bar => iabs
14 end function
15 end