Skip to content

Commit

Permalink
d: remove unnecessary comparison from YYParser.parse()
Browse files Browse the repository at this point in the history
* data/skeletons/lalr1.d: Here.
  • Loading branch information
adelavais authored and akimd committed Dec 21, 2020
1 parent c0f3b55 commit 2b4451c
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions data/skeletons/lalr1.d
Original file line number Diff line number Diff line change
Expand Up @@ -591,12 +591,9 @@ m4_popdef([b4_at_dollar])])dnl
/* If just tried and failed to reuse lookahead token after an
* error, discard it. */
if (yytoken <= ]b4_symbol(eof, [kind])[)
{
/* Return failure if at end of input. */
if (yytoken == ]b4_symbol(eof, [kind])[)
return false;
}
/* Return failure if at end of input. */
if (yytoken == ]b4_symbol(eof, [kind])[)
return false;
else
yytoken = ]b4_symbol(empty, kind)[;
}
Expand Down

0 comments on commit 2b4451c

Please sign in to comment.