From ee2897efdb1fe6e538265cc12ba0ce58dcbaf2c5 Mon Sep 17 00:00:00 2001 From: Richard Kenner Date: Fri, 12 May 1995 07:08:56 -0400 Subject: [PATCH] Adjust number of shift/reduce conflicts. (parm): Support attributes. From-SVN: r9638 --- gcc/c-parse.in | 35 +++++++++++++++++++++++------------ 1 file changed, 23 insertions(+), 12 deletions(-) diff --git a/gcc/c-parse.in b/gcc/c-parse.in index b4eea8ec2291..55c350d4912f 100644 --- a/gcc/c-parse.in +++ b/gcc/c-parse.in @@ -27,10 +27,10 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ written by AT&T, but I have never seen it. */ ifobjc -%expect 42 +%expect 46 end ifobjc ifc -%expect 30 +%expect 34 /* These are the 23 conflicts you should get in parse.output; the state numbers may vary if minor changes in the grammar are made. @@ -2118,16 +2118,27 @@ parms: /* A single parameter declaration or parameter type name, as found in a parmlist. */ parm: - typed_declspecs parm_declarator - { $$ = build_tree_list ($1, $2) ; } - | typed_declspecs notype_declarator - { $$ = build_tree_list ($1, $2) ; } - | typed_declspecs absdcl - { $$ = build_tree_list ($1, $2); } - | declmods notype_declarator - { $$ = build_tree_list ($1, $2) ; } - | declmods absdcl - { $$ = build_tree_list ($1, $2); } + typed_declspecs parm_declarator maybe_attribute + { $$ = build_tree_list (build_tree_list ($1, $2), + build_tree_list (prefix_attributes, + $3)); } + | typed_declspecs notype_declarator maybe_attribute + { $$ = build_tree_list (build_tree_list ($1, $2), + build_tree_list (prefix_attributes, + $3)); } + | typed_declspecs absdcl maybe_attribute + { $$ = build_tree_list (build_tree_list ($1, $2), + build_tree_list (prefix_attributes, + $3)); } + | declmods notype_declarator maybe_attribute + { $$ = build_tree_list (build_tree_list ($1, $2), + build_tree_list (prefix_attributes, + $3)); } + + | declmods absdcl maybe_attribute + { $$ = build_tree_list (build_tree_list ($1, $2), + build_tree_list (prefix_attributes, + $3)); } ; /* This is used in a function definition