3 ! Code contributed by Salvatore Filippone.
6 integer, parameter :: int_
= 1
7 integer, parameter :: bnd_
= 2
12 ! This interface is extending the SIZE intrinsic procedure,
13 ! which led to a segmentation fault when trying to resolve
14 ! the intrinsic symbol name.
17 module procedure get_fld_size
20 function get_fld_size(f
)
21 integer :: get_fld_size(2)
22 type(fld
), intent(in
) :: f
23 get_fld_size(int_
) = f
%size(int_
)
24 get_fld_size(bnd_
) = f
%size(bnd_
)
25 end function get_fld_size
32 real(kind(1.d0
)), pointer :: x(:) => null()
35 module procedure get_s_fld_x
38 function get_s_fld_x(fld
)
39 real(kind(1.d0
)), pointer :: get_s_fld_x(:)
40 type(s_fld
), intent(in
) :: fld
42 end function get_s_fld_x
43 end module class_s_fld
47 subroutine solve_s_foo(phi
,var
)
49 type(s_fld
), intent(inout
) :: phi
50 real(kind(1.d0
)), intent(out
), optional
:: var
52 real(kind(1.d0
)), pointer :: x(:)
55 end subroutine solve_s_foo
56 end module class_s_foo
57 ! { dg-final { cleanup-modules "class_s_fld class_fld class_s_foo" } }