diff options
author | Joseph Myers <joseph@codesourcery.com> | 2007-09-02 01:11:20 +0100 |
---|---|---|
committer | Joseph Myers <jsm28@gcc.gnu.org> | 2007-09-02 01:11:20 +0100 |
commit | b09869ff41aa77377645d60115d77177acd3a8cd (patch) | |
tree | 24de65c7de3de7f1f82248b440ebe5639bb4788c /gcc/c-decl.c | |
parent | 15dc95cbcc21b31f3b5ae50d6172db3c4f4894b1 (diff) | |
download | gcc-b09869ff41aa77377645d60115d77177acd3a8cd.zip gcc-b09869ff41aa77377645d60115d77177acd3a8cd.tar.gz gcc-b09869ff41aa77377645d60115d77177acd3a8cd.tar.bz2 |
re PR middle-end/33272 (Compiler does not take advantage of restrict)
PR middle-end/33272
* c-decl.c (grokdeclarator): Apply qualifiers to type of parameter
decayed from array.
testsuite:
* gcc.dg/c99-arraydecl-3.c: New test.
From-SVN: r128018
Diffstat (limited to 'gcc/c-decl.c')
-rw-r--r-- | gcc/c-decl.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/c-decl.c b/gcc/c-decl.c index 714cf62..d2f4832 100644 --- a/gcc/c-decl.c +++ b/gcc/c-decl.c @@ -4719,6 +4719,8 @@ grokdeclarator (const struct c_declarator *declarator, type = c_build_qualified_type (type, type_quals); type = build_pointer_type (type); type_quals = array_ptr_quals; + if (type_quals) + type = c_build_qualified_type (type, type_quals); /* We don't yet implement attributes in this context. */ if (array_ptr_attrs != NULL_TREE) |