diff options
Diffstat (limited to 'gcc/testsuite/gcc.dg/struct-parse-2.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/struct-parse-2.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/struct-parse-2.c b/gcc/testsuite/gcc.dg/struct-parse-2.c new file mode 100644 index 0000000..559411a --- /dev/null +++ b/gcc/testsuite/gcc.dg/struct-parse-2.c @@ -0,0 +1,13 @@ +/* PR c/35437 */ +/* { dg-do "compile" } */ + +struct A +{ + int i; + struct A a; /* { dg-error "has incomplete type" } */ +}; + +void foo() +{ + struct A b = { 0 }; +} |