aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/20040322-1.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2004-03-22 16:28:06 +0100
committerJakub Jelinek <jakub@gcc.gnu.org>2004-03-22 16:28:06 +0100
commitd915eec0db44e5b9c50585ea77cf12daaf71de4a (patch)
treee522b26caa2d20f25e0ae5a80dbd037ad709e5a2 /gcc/testsuite/gcc.dg/20040322-1.c
parent19a0330388adbe2baae823dd85cdab560d83f456 (diff)
downloadgcc-d915eec0db44e5b9c50585ea77cf12daaf71de4a.zip
gcc-d915eec0db44e5b9c50585ea77cf12daaf71de4a.tar.gz
gcc-d915eec0db44e5b9c50585ea77cf12daaf71de4a.tar.bz2
re PR c/14069 (This input file lets gcc crash)
PR c/14069 * c-decl.c (finish_struct): Change type of incorrect flexible array field into error_mark_node. * gcc.dg/20040322-1.c: New test. From-SVN: r79832
Diffstat (limited to 'gcc/testsuite/gcc.dg/20040322-1.c')
-rw-r--r--gcc/testsuite/gcc.dg/20040322-1.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/20040322-1.c b/gcc/testsuite/gcc.dg/20040322-1.c
new file mode 100644
index 0000000..af5e0b4
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/20040322-1.c
@@ -0,0 +1,4 @@
+/* PR c/14069 */
+/* { dg-do compile } */
+struct S { int a; char b[]; char *c; }; /* { dg-error "error" "flexible array member not" } */
+struct S s = { .b = "foo", .c = .b }; /* { dg-error "error" "parse error before" } */