Allow different parse stack heads to lex differently

This commit is contained in:
Max Brunsfeld 2015-11-18 08:47:15 -08:00
parent 484721b0c2
commit 64874449e4
4 changed files with 152 additions and 76 deletions

View file

@ -110,6 +110,9 @@ TSLexer ts_lexer_make() {
}
void ts_lexer_reset(TSLexer *self, TSLength position) {
if (ts_length_eq(position, self->current_position))
return;
self->token_start_position = position;
self->token_end_position = position;
self->current_position = position;