Simplify the i18n of the error messages.

* data/lalr1.cc: Comment changes.
	* data/yacc.c (yysyntax_error): Rewrite, using a switch as in
	lalr1.cc instead of building dynamically the format string.
This commit is contained in:
Akim Demaille
2008-12-11 00:59:13 +01:00
parent e5fa6147ef
commit eeb2942237
3 changed files with 43 additions and 43 deletions

View File

@@ -1393,7 +1393,8 @@ b4_error_verbose_if([int yystate, int yytoken],
int yychecklim = yylast_ - yyn + 1;
int yyxend = yychecklim < yyntokens_ ? yychecklim : yyntokens_;
// Number of "expected" tokens.
// Number of reported tokens (one for the "unexpected", one per
// "expected").
size_t yycount = 0;
// Its maximum.
enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };