Fix failure to find repairs when extra tokens precede the detection point
This commit is contained in:
parent
dcf3beb393
commit
a3c943d88e
1 changed files with 3 additions and 1 deletions
|
|
@ -565,7 +565,9 @@ static inline const TSParseAction *ts_parser__reductions_after_sequence(
|
|||
size_t child_count = 0;
|
||||
*count = 0;
|
||||
|
||||
for (size_t i = 0; i < tree_count_below; i++) {
|
||||
for (size_t i = 0; i < trees_below->size; i++) {
|
||||
if (child_count == tree_count_below)
|
||||
break;
|
||||
TSTree *tree = trees_below->contents[trees_below->size - 1 - i];
|
||||
const TSParseAction *action =
|
||||
ts_language_last_action(self->language, state, tree->symbol);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue