Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / CXX / special / class.init / class.base.init / p9-0x.cpp
blobca5e8072d82f7c251d4dd11422c37947b320fce7
1 // RUN: %clang_cc1 -triple x86_64-pc-linux-gnu -std=c++11 %s -O1 -emit-llvm -o - | FileCheck %s
3 struct S {
4 int n = 10;
5 int m = 2 * n;
7 S() {}
8 S(int a) : n(a) {}
9 S(int a, int b) : n(a), m(b) {}
11 struct T {
12 T *that = this;
16 template<typename T>
17 struct U {
18 T *r = &q;
19 T q = 42;
20 U *p = this;
23 S a;
24 // CHECK: @a = {{.*}} { i32 10, i32 20 }
26 S b(5);
27 // CHECK: @b = {{.*}} { i32 5, i32 10 }
29 S c(3, 9);
30 // CHECK: @c = {{.*}} { i32 3, i32 9 }
32 S::T d;
33 // CHECK: @d = {{.*}} { {{.*}} @d }
35 U<S> e;
36 // CHECK: @e = {{.*}} { {{.*}} { i32 42, i32 84 }, {{.*}} @e }