diff options
| author | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-04-24 22:26:10 +0000 |
|---|---|---|
| committer | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-04-24 22:26:10 +0000 |
| commit | db40a8345ccf8bef7302506d672cead741d2f95f (patch) | |
| tree | 1cbecc14650e6c8a4519df95cf7416b13f37534e /gcc/c-decl.c | |
| parent | 497bb0230ff301fae31e259a009994db1cbf0bb4 (diff) | |
| download | ppe42-gcc-db40a8345ccf8bef7302506d672cead741d2f95f.tar.gz ppe42-gcc-db40a8345ccf8bef7302506d672cead741d2f95f.zip | |
* c-decl.c (grokdeclarator): Don't pedwarn variable sized arrays
for c99.
* gcc.dg/c90-vla-1.c, gcc.dg/c99-vla-1.c: New.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@52738 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/c-decl.c')
| -rw-r--r-- | gcc/c-decl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/c-decl.c b/gcc/c-decl.c index 71ece88d6fe..fed2e5084df 100644 --- a/gcc/c-decl.c +++ b/gcc/c-decl.c @@ -4381,7 +4381,7 @@ grokdeclarator (declarator, declspecs, decl_context, initialized) even if it is (eg) a const variable with known value. */ size_varies = 1; - if (pedantic) + if (!flag_isoc99 && pedantic) { if (TREE_CONSTANT (size)) pedwarn ("ISO C89 forbids array `%s' whose size can't be evaluated", |

