Reset lexer correctly when old input was blank
This commit is contained in:
parent
e32fe07432
commit
8a146a9bef
4 changed files with 28 additions and 6 deletions
|
|
@ -342,8 +342,7 @@ static void ts_parser__start(TSParser *self, TSInput input,
|
|||
LOG("new_parse");
|
||||
}
|
||||
|
||||
self->lexer.input = input;
|
||||
ts_lexer_reset(&self->lexer, ts_length_zero(), ts_point_zero());
|
||||
ts_lexer_set_input(&self->lexer, input);
|
||||
ts_stack_clear(self->stack);
|
||||
|
||||
LookaheadState head_state = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue