5 ! Pureness check for TPB/PPC in specification expressions
7 ! Based on a test case of Thorsten Ohl
14 procedure(p1_type
), nopass
, pointer :: p1
=> NULL()
16 procedure
, nopass
:: tbp
=> p1_type
19 subroutine proc (t1
, t2
)
20 type(t
), intent(in
) :: t1
, t2
21 integer, dimension(t1
%p1(), t2
%tbp()) :: table
23 pure
function p1_type()
28 type(t
), intent(inout
) :: t1
36 procedure(p1_type
), nopass
, pointer :: p1
=> NULL()
38 procedure
, nopass
:: tbp
=> p1_type
41 subroutine proc (t1
, t2
)
42 type(t
), intent(in
) :: t1
, t2
43 integer, dimension(t1
%p1()) :: table1
! { dg-error "must be PURE" }
44 integer, dimension(t2
%tbp()) :: table2
! { dg-error "must be PURE" }
52 ! { dg-final { cleanup-modules "m m2" } }