Debian Codegraph @

gcc/testsuite/g++.dg/cpp0x/constexpr-delegating.C

raw
1 // PR c++/51526
2 // { dg-do compile { target c++11 } }
3
4 const int j = 42;
5
6 struct S {
7 int i;
8 constexpr S(int i) : i(i) {}
9 constexpr S() : S(j) {}
10 };
11
12 constexpr S s{};
13
14 #define SA(X) static_assert((X),#X)
15 SA(s.i == 42);