From: Akim Demaille Date: Wed, 27 Aug 2003 07:00:10 +0000 (+0000) Subject: * data/lalr1.cc (yyparse) [__GNUC__]: "Use" yyerrorlab to pacify X-Git-Tag: BISON-2_0~208 X-Git-Url: https://git.saurik.com/bison.git/commitdiff_plain/62b6aef925259b8d513d36e581e6757e19ea437e * data/lalr1.cc (yyparse) [__GNUC__]: "Use" yyerrorlab to pacify GCC warnings. --- diff --git a/ChangeLog b/ChangeLog index a7b160a5..466d8de8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2003-08-27 Akim Demaille + + * data/lalr1.cc (yyparse) [__GNUC__]: "Use" yyerrorlab to pacify + GCC warnings. + 2003-08-26 Akim Demaille * config/announce-gen (print_changelog_deltas): Neutralize "<#" as diff --git a/data/lalr1.cc b/data/lalr1.cc index c434c9bd..4fe3c2ad 100644 --- a/data/lalr1.cc +++ b/data/lalr1.cc @@ -573,6 +573,13 @@ b4_syncline([@oline@], [@ofile@])[ `---------------------------------------------------*/ yyerrorlab: +#ifdef __GNUC__ + /* Pacify GCC when the user code never invokes YYERROR and the label + yyerrorlab therefore never appears in user code. */ + if (0) + goto yyerrorlab; +#endif + state_stack_.pop (len_); semantic_stack_.pop (len_); location_stack_.pop (len_);