2 ! { dg-options "-std=f2003" }
3 ! { dg-compile-aux-modules "test_common_binding_labels_2.f03" }
5 module test_common_binding_labels_2_main
6 use, intrinsic :: iso_c_binding, only: c_double, c_int
9 common /mycom/ r, s ! { dg-error "same binding name" }
12 ! this next line is an error; if a common block is bind(c), the binding label
13 ! for it must match across all scoping units that declare it.
14 bind(c, name="my_common_block_2") :: /mycom/
16 common /com2/ i ! { dg-error "same binding name" }
18 bind(c, name="mycom2") /com2/
19 end module test_common_binding_labels_2_main
22 use test_common_binding_labels_2 ! { dg-error "same binding name" }
23 use test_common_binding_labels_2_main ! { dg-error "same binding name" }
25 ! { dg-final { cleanup-modules "test_common_binding_labels_2" } }