1 // RUN: %clang_cc1 -triple x86_64-apple-darwin10 -fno-use-cxa-atexit -fapple-kext -emit-llvm -o - %s | FileCheck %s 2 3 // CHECK: @_ZN5test01aE = global [[A:%.*]] zeroinitializer 4 // CHECK: @llvm.global_ctors = appending global {{.*}} { i32 65535, void ()* [[CTOR0:@.*]], i8* null } 5 // CHECK: @llvm.global_dtors = appending global {{.*}} { i32 65535, void ()* [[DTOR0:@.*]], i8* null } 6 7 // rdar://11241230 8 namespace test0 { 9 struct A { A(); ~A(); }; 10 A a; 11 } 12 // CHECK: define internal void [[CTOR0_:@.*]]() 13 // CHECK: call void @_ZN5test01AC1Ev([[A]]* @_ZN5test01aE) 14 // CHECK-NEXT: ret void 15 16 // CHECK: define internal void [[CTOR0]]() 17 // CHECK: call void [[CTOR0_]]() 18 // CHECK-NEXT: ret void 19 20 // CHECK: define internal void [[DTOR0]]() 21 // CHECK: call void @_ZN5test01AD1Ev([[A]]* @_ZN5test01aE) 22 // CHECK-NEXT: ret void 23