mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-14 23:03:04 +00:00
yychar cannot be empty in yyerrlab.
* TODO (yychar == yyempty_): New. * data/lalr1.cc: Remove the handling of this case. This eases forthcoming changes related to yychar and yytranslate.
This commit is contained in:
16
TODO
16
TODO
@@ -54,6 +54,22 @@ what it should look like. For instance what follows crashes.
|
||||
return yyparse ();
|
||||
}
|
||||
|
||||
** yychar == yyempty_
|
||||
The code in yyerrlab reads:
|
||||
|
||||
if (yychar <= YYEOF)
|
||||
{
|
||||
/* Return failure if at end of input. */
|
||||
if (yychar == YYEOF)
|
||||
YYABORT;
|
||||
}
|
||||
|
||||
There are only two yychar that can be <= YYEOF: YYEMPTY and YYEOF.
|
||||
But I can't produce the situation where yychar is YYEMPTY here, is it
|
||||
really possible? The test suite does not exercise this case.
|
||||
|
||||
This shows that it would be interesting to manage to install skeleton
|
||||
coverage analysis to the test suite.
|
||||
|
||||
* Header guards
|
||||
|
||||
|
||||
Reference in New Issue
Block a user