Open pokey opened 1 year ago
In the meantime, If the file is particularly large, it might be better to disable treesitter scopes entirely, similarly to how VS code disable syntax highlighting on massive files.
Fwiw we're already parsing the file; this issue is just about running the tree query, which is likely many orders of magnitude faster
In #1800, we introduced a workaround for https://github.com/tree-sitter/tree-sitter/issues/2484, which means that we no longer restrict the search range for our tree-sitter queries. That workaround has no impact on correctness, but could have performance implications for large files, as we get all matches and then filter them after the fact, rather than restricting to the range we care about. Once https://github.com/tree-sitter/tree-sitter/issues/2484 is fixed, we'd like to reactivate our code that restricts the search range, by rolling back #1800