Don't consume after error recovery.

recoverInline should handle making sure that the token stream is
advanced to the appropriate position. It is difficult for the caller to
do that, as recoverInline may create a "new" token that is not actually
in the stream.
This commit is contained in:
Michael Peyton Jones 2015-01-19 17:42:37 +00:00
parent dea7c768d4
commit 9e09e6a9c0
1 changed files with 2 additions and 1 deletions

View File

@ -647,8 +647,9 @@ setState(<m.stateNumber>);
<capture>
if ( <if(invert)><m.varName> \<= 0 || <else>!<endif>(<expr>) ) {
<if(m.labels)><m.labels:{l | <labelref(l)> = (Token)}><endif>_errHandler.recoverInline(this);
} else {
consume();
}
consume();
>>
Wildcard(w) ::= <<