summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/20030331-2.c
diff options
context:
space:
mode:
authormmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4>2003-04-01 07:35:11 +0000
committermmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4>2003-04-01 07:35:11 +0000
commitfac69c46176dda4705ccbc71bde6d31c626d1757 (patch)
tree20f14569b12a88ace119697818b500699afb7a34 /gcc/testsuite/gcc.dg/20030331-2.c
parent5d7b86061ff0eeedff84297357034f21b1f8220d (diff)
downloadgcc-fac69c46176dda4705ccbc71bde6d31c626d1757.tar.gz
PR c/9936
* c-decl.c (grokdeclarator): Clear SAVE_EXPR_CONTEXT for variably-sized arrays in parameters. (set_save_expr_context): New function. (c_expand_body): Use it, via walk_tree. PR c/9936 * gcc.dg/20030331-2.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@65128 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.dg/20030331-2.c')
-rw-r--r--gcc/testsuite/gcc.dg/20030331-2.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/20030331-2.c b/gcc/testsuite/gcc.dg/20030331-2.c
new file mode 100644
index 00000000000..210524da456
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/20030331-2.c
@@ -0,0 +1,10 @@
+// { dg-options "" }
+
+int foo() {
+ int yd;
+ float in[1][yd];
+
+ static void bar() {
+ printf("%p\n",in[0]);
+ }
+}