3 use, intrinsic :: iso_c_binding, only: c_double
6 common /mycom/ r, s ! { dg-error "does not match" }
9 bind(c, name="my_common_block") :: /mycom/
13 use, intrinsic :: iso_c_binding, only: c_double, c_int
19 bind(c, name="my_common_block") :: /mycom/
21 common /com2/ i ! { dg-error "does not match" }
23 bind(c, name="") /com2/
27 use, intrinsic :: iso_c_binding, only: c_double, c_int
30 common /mycom/ r, s ! { dg-error "does not match" }
33 ! this next line is an error; if a common block is bind(c), the binding label
34 ! for it must match across all scoping units that declare it.
35 bind(c, name="my_common_block_2") :: /mycom/
37 common /com2/ i ! { dg-error "does not match" }
39 bind(c, name="mycom2") /com2/