Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / CodeGenCXX / thunks-available-externally.cpp
blob01e494717ebf899ba93adf75d8fe5f12b274f28f
1 // RUN: %clang_cc1 %s -I%S -triple=x86_64-apple-darwin10 -emit-llvm-only -O3
3 // Check that we don't assert on this case.
4 namespace Test1 {
6 struct Incomplete;
8 struct A {
9 virtual void f();
10 virtual void g(Incomplete);
11 virtual void h();
12 virtual void i();
13 int a;
16 struct B {
17 virtual void f();
18 virtual void g(Incomplete);
19 virtual void h();
20 virtual void i();
21 int b;
24 struct C : A, B {
25 C();
27 virtual void f();
28 virtual void g(Incomplete);
29 virtual void h();
30 virtual void i();
33 void C::h() { }
35 C::C() { }
37 void C::i() { }
41 namespace Test2 {
43 struct A {
44 virtual void f();
45 int a;
48 struct B {
49 virtual void f();
50 int b;
53 struct C : A, B {
54 virtual void f();
57 static void f(B* b) {
58 b->f();
63 // Test that we don't assert.
64 namespace Test3 {
66 struct A {
67 virtual ~A();
69 int a;
72 struct B : A { };
73 struct C : virtual B { };
75 void f() {
76 C c;