c: Fix up pointer types to may_alias structures [PR114493]
[official-gcc.git] / gcc / testsuite / gfortran.dg / proc_decl_14.f90
blobd30ee7a9067be0ade700041affab403976dd607a
1 ! { dg-do compile }
2 ! PR fortran/35830
4 abstract interface
5 function ptrfunc()
6 integer, pointer :: ptrfunc
7 end function ptrfunc
8 elemental subroutine elem(a)
9 integer,intent(in) :: a
10 end subroutine elem
11 function dims()
12 integer :: dims(3)
13 end function dims
14 end interface
16 procedure(ptrfunc) :: func_a
17 procedure(elem) :: func_b
18 procedure(dims) :: func_c
20 integer, pointer :: ptr
21 integer :: array(3)
23 ptr => func_a()
24 call func_b([1,2,3])
25 array = func_c()
26 end