Fix PR c++/69139 (deduction failure with trailing return type)
[official-gcc.git] / gcc / testsuite / g++.dg / cpp0x / nsdmi-template14.C
blob1a00ec0d6a9f351b0769aa917ca47ede0187b144
1 // PR c++/58583
2 // { dg-do compile { target c++11 } }
4 template<int> struct A
6   int i = (A<0>(), 0); // { dg-error "recursive instantiation of non-static data" }
7 };
9 A<0> a;
11 template<int N> struct B
13   B* p = new B<N>; // { dg-error "recursive instantiation of non-static data" }
16 B<1> x;
18 struct C
20   template<int N> struct D
21   {
22     D* p = new D<0>;
23   };