xref: /aosp_15_r20/external/clang/test/CodeGenCXX/constructor-attr.cpp (revision 67e74705e28f6214e480b399dd47ea732279e315)
1 // RUN: %clang_cc1 -triple %itanium_abi_triple -emit-llvm -o - %s | FileCheck %s
2 
3 // CHECK: @llvm.global_ctors
4 
5 // PR6521
6 void bar();
7 struct Foo {
8   // CHECK-LABEL: define linkonce_odr {{.*}}void @_ZN3Foo3fooEv
fooFoo9   static void foo() __attribute__((constructor)) {
10     bar();
11   }
12 };
13