1 // PR c++/33841 2 // { dg-do compile } 3 4 template<int> struct A 5 { 6 // multiple errors below: missing semicolon, no anonymous structs, etc. 7 struct {} : 2; // { dg-error "" } 8 }; 9 10 template<int> struct B 11 { 12 int a; 13 // multiple errors below: missing semicolon, no anonymous structs, etc. 14 struct {} : 2; // { dg-error "" } 15 int b; 16 }; 17 18 struct C : A<0> {}; 19 struct D : B<0> {}; 20