Add wasm binding for running tree queries in a limited range
This commit is contained in:
parent
0528ad5f58
commit
49ce2fddb9
6 changed files with 143 additions and 24 deletions
|
|
@ -96,7 +96,8 @@ TSFieldId ts_language_field_id_for_name(
|
|||
for (TSSymbol i = 1; i < count + 1; i++) {
|
||||
switch (strncmp(name, self->field_names[i], name_length)) {
|
||||
case 0:
|
||||
return i;
|
||||
if (self->field_names[i][name_length] == 0) return i;
|
||||
break;
|
||||
case -1:
|
||||
return 0;
|
||||
default:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue