1 // RUN: %clang_cc1 -fno-rtti -fcxx-exceptions -fexceptions -Wno-dynamic-exception-spec %s -triple=x86_64-apple-darwin10 -emit-llvm -o - %std_cxx98- | FileCheck %s
3 // CHECK: @_ZTIN5test11AE = linkonce_odr constant
4 // CHECK: @_ZTIN5test11BE = linkonce_odr constant
5 // CHECK: @_ZTIN5test11CE = linkonce_odr constant
6 // CHECK: @_ZTIPN5test11DE = linkonce_odr constant {{.*}} @_ZTIN5test11DE
7 // CHECK: @_ZTIN5test11DE = linkonce_odr constant
9 // PR6974: this shouldn't crash
21 // These classes have key functions defined out-of-line. Under
22 // normal circumstances, we wouldn't generate RTTI for them; under
23 // -fno-rtti, we generate RTTI only when required by EH. But
24 // everything gets hidden visibility because we assume that all
25 // users are also compiled under -fno-rtti and therefore will be
26 // emitting RTTI regardless of key function.
27 class A
{ virtual void foo(); };
28 class B
{ virtual void foo(); };
29 class C
{ virtual void foo(); };
30 class D
{ virtual void foo(); };
38 void test1() throw(B
) {