Break circular dependency between FIR dialect and utilities
[llvm-project.git] / flang / test / Lower / c-interoperability-bindc-variables.f90
bloba8e8b3f614dfbe28a040afb5e7a658e7bc672193
1 ! Test lowering of BIND(C) variables
2 ! RUN: bbc -emit-fir %s -o - | FileCheck %s
4 block data
5 integer :: x, y
6 common /fortran_name/ x, y
7 ! CHECK-LABEL: fir.global common @c_name
8 bind(c, name="c_name") /fortran_name/
9 end block data
11 module some_module
12 ! CHECK-LABEL: fir.global @tomato
13 integer, bind(c, name="tomato") :: apple = 42
14 end module