2 ! { dg-options "-fcoarray=lib -fdump-tree-original" }
4 ! Allocate/deallocate with libcaf.
8 integer(4), allocatable
:: xx
[:], yy(:)[:]
10 character(len
=200) :: errmsg
11 allocate(xx
[*], stat
=stat
, errmsg
=errmsg
)
12 allocate(yy(2)[*], stat
=stat
, errmsg
=errmsg
)
13 deallocate(xx
,yy
,stat
=stat
, errmsg
=errmsg
)
16 ! { dg-final { scan-tree-dump-times "_gfortran_caf_register \\(4, 1, &xx.token, \\(void \\*\\) &xx, &stat.., &errmsg, 200\\);" 1 "original" } }
17 ! { dg-final { scan-tree-dump-times "_gfortran_caf_register \\(8, 1, &yy.token, \\(void \\*\\) &yy, &stat.., &errmsg, 200\\);" 1 "original" } }
18 ! { dg-final { scan-tree-dump-times "_gfortran_caf_deregister .&xx.token, 0, &stat.., &errmsg, 200.;" 1 "original" } }
19 ! { dg-final { scan-tree-dump-times "_gfortran_caf_deregister .&yy.token, 0, &stat.., &errmsg, 200.;" 1 "original" } }
20 ! { dg-final { scan-tree-dump-times "_gfortran_caf_deregister .&yy.token, 0, 0B, 0B, 0.;" 1 "original" } }
21 ! { dg-final { scan-tree-dump-times "_gfortran_caf_deregister .&xx.token, 0, 0B, 0B, 0.;" 1 "original" } }