1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
// PR c++/53733 // { dg-do compile { target c++11 } } template<typename T> struct wrap { wrap() = default; wrap(wrap&&) = default; // Line 5 wrap(const wrap&) = default; T t; }; struct S { S() = default; S(const S&){} S(S&&) = default; }; typedef wrap<const S> W; W get() { return W(); } // Line 19 int main() {}