Skip to content
forked from neovim/neovim

Commit

Permalink
fix(treesitter): bump match limit up (neovim#18400)
Browse files Browse the repository at this point in the history
This avoids ignoring too many match results, and avoid highlighting
being blank in some files.

(cherry picked from commit e453b63)

Co-authored-by: Thomas Vigouroux <thomas.vigouroux@protonmail.com>
  • Loading branch information
github-actions[bot] and vigoux committed May 3, 2022
1 parent 7567d21 commit e502e81
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/nvim/lua/treesitter.c
Original file line number Diff line number Diff line change
Expand Up @@ -1122,7 +1122,7 @@ static int node_rawquery(lua_State *L)
// TODO(clason): API introduced after tree-sitter release 0.19.5
// remove guard when minimum ts version is bumped to 0.19.6+
#ifdef NVIM_TS_HAS_SET_MATCH_LIMIT
ts_query_cursor_set_match_limit(cursor, 32);
ts_query_cursor_set_match_limit(cursor, 64);
#endif
ts_query_cursor_exec(cursor, query, node);

Expand Down

0 comments on commit e502e81

Please sign in to comment.