Debian Codegraph @

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

raw
1 // PR c++/55432
2 // { dg-do compile { target c++11 } }
3
4 struct tag_t{} tag{};
5
6 constexpr tag_t const& pass(tag_t & t)
7 {
8 return t;
9 }
10
11 struct S
12 {
13 constexpr S(tag_t) {};
14 };
15
16 struct T
17 {
18 S mem;
19 T( tag_t & args ) : mem(pass(args)) {}
20 };
21
22 T t(tag);