aboutsummaryrefslogtreecommitdiffstats
path: root/cparser/pre_parser.mly
diff options
context:
space:
mode:
authorFrançois Pottier <francois.pottier@inria.fr>2015-10-08 01:20:31 +0200
committerFrançois Pottier <francois.pottier@inria.fr>2015-10-23 12:51:02 +0200
commit44b910bb829f6e5920b0a51985624c345019711e (patch)
treec484f06fefde7de1aaa0cbe52dc09fb1f2279412 /cparser/pre_parser.mly
parent17733e430b0c0a19853e1367ca38282a943e0c76 (diff)
downloadcompcert-kvx-44b910bb829f6e5920b0a51985624c345019711e.tar.gz
compcert-kvx-44b910bb829f6e5920b0a51985624c345019711e.zip
Factorized [declaration_specifier_no_type].
This saves a few states.
Diffstat (limited to 'cparser/pre_parser.mly')
-rw-r--r--cparser/pre_parser.mly10
1 files changed, 7 insertions, 3 deletions
diff --git a/cparser/pre_parser.mly b/cparser/pre_parser.mly
index 78641e58..0aa884c9 100644
--- a/cparser/pre_parser.mly
+++ b/cparser/pre_parser.mly
@@ -354,10 +354,14 @@ storage_class_specifier_no_typedef:
(* [declaration_specifiers_no_type] matches declaration specifiers
that do not contain either "typedef" nor type specifiers. *)
+declaration_specifier_no_type:
+| storage_class_specifier_no_typedef
+| type_qualifier
+| function_specifier
+ {}
+
declaration_specifiers_no_type:
-| storage_class_specifier_no_typedef declaration_specifiers_no_type?
-| type_qualifier declaration_specifiers_no_type?
-| function_specifier declaration_specifiers_no_type?
+| declaration_specifier_no_type declaration_specifiers_no_type?
{}
(* [declaration_specifiers_no_typedef_name] matches declaration