1 ! Test the host_data construct with optional arguments.
2 ! Based on host_data-1.f90.
5 ! { dg-additional-options "-cpp" }
11 integer, pointer :: ip
, iph
13 ! Assign the same targets
20 subroutine foo(iph
, ip
)
21 integer, pointer :: iph
22 integer, pointer, optional
:: ip
25 !$acc host_data use_device(ip)
27 ! Test how the pointers compare inside a host_data construct
30 if (.not
. associated(ip
, iph
)) STOP 1
32 if (associated(ip
, iph
)) STOP 2