summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/binding_label_tests_4.f03
blob: 5a0767d878555d43fdf57aec0c45f118463d03be (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
! { dg-do compile }
module A
  use, intrinsic :: iso_c_binding
contains
  subroutine pA() bind(c, name='printf') ! { dg-error "collides" }
    print *, 'hello from pA'
  end subroutine pA
end module A

module B
  use, intrinsic :: iso_c_binding

contains
  subroutine pB() bind(c, name='printf') ! { dg-error "collides" }
    print *, 'hello from pB'
  end subroutine pB
end module B

module C
use A
use B ! { dg-error "Can't open module file" }
end module C