2 ! { dg-additional-sources bind_c_coms_driver.c }
4 ! the -w option is to prevent the warning about long long ints
6 ! { dg-additional-options "-fcommon" { target hppa*-*-hpux* } }
7 use, intrinsic :: iso_c_binding
14 bind(c
) :: /COM
/, /SINGLE
/, /MYCOM
/
16 common /MYCOM
/ LONG_INTS
17 integer(c_long
) :: LONG_INTS
18 common /MYCOM2
/ LONG_LONG_INTS
19 integer(c_long_long
) :: long_long_ints
23 integer(c_int
) :: i
, j
24 bind(c
, name
="f03_com2") /com2
/
27 integer(c_int
) :: m
, n
28 bind(c
, name
="") /com3
/
31 subroutine test_coms() bind(c
)
35 long_ints
= long_ints
+ 1
36 long_long_ints
= long_long_ints
+ 1
42 end subroutine test_coms
43 end module bind_c_coms
46 use, intrinsic :: iso_c_binding
, only
: c_int
48 integer(c_int
) :: m
, n
49 bind(c
, name
="") /com3
/
50 end module bind_c_coms_2