Pass the token type to yysyntax_error.

* data/yacc.c (yysyntax_error): Take the transated token instead
	of the raw number.
	Adjust callers.
	* TODO: Update.
This commit is contained in:
Akim Demaille
2008-12-11 09:48:49 +01:00
parent 5860cc8c1c
commit 84eedf86fe
3 changed files with 14 additions and 11 deletions

4
TODO
View File

@@ -156,10 +156,6 @@ other improvements and also made it faster (probably because memory
management is performed once instead of three times). I suggest that
we do the same in yacc.c.
** yysyntax_error
In lalr1.cc we invoke it with the translated lookahead (yytoken), and
yacc.c uses yychar. I don't see why.
** yysyntax_error
The code bw glr.c and yacc.c is really alike, we can certainly factor
some parts.