blob: 19a88d739acdf2e5e2413ed146a8d61c341d1312 [file] [log] [blame]
Argyrios Kyrtzidisdd7744d2010-08-16 17:27:08 +00001// RUN: %clang_cc1 -fsyntax-only -verify %s
2
3struct S {
4 S(); // expected-note {{because type 'S' has a user-declared constructor}}
5};
6
David Blaikie2b79c322011-10-19 22:43:29 +00007struct { // expected-error {{anonymous structs and classes must be class members}}
8};
9
Argyrios Kyrtzidisdd7744d2010-08-16 17:27:08 +000010struct E {
11 struct {
12 S x; // expected-error {{anonymous struct member 'x' has a non-trivial constructor}}
13 };
David Blaikie2b79c322011-10-19 22:43:29 +000014 static struct {
15 };
Argyrios Kyrtzidisdd7744d2010-08-16 17:27:08 +000016};