fix(query): use explicitly the legacy behavior

After
6913c5e1d9
it is necessary to opt-in explicitly to the old behavior.

Signed-off-by: Jonas Dujava <jonas.dujava@gmail.com>
This commit is contained in:
Jonas Dujava 2024-09-02 11:11:45 +02:00 committed by Lewis Russell
parent 0ec9a8e00c
commit e6cc783b74

View file

@ -72,7 +72,7 @@ local context_range = cache.memoize(function(node, query)
-- max_start_depth depth is only supported in nvim 0.10. It is ignored on
-- versions 0.9 or less. It is only needed to improve performance
for _, match in query:iter_matches(node, bufnr, 0, -1, { max_start_depth = 0 }) do
for _, match in query:iter_matches(node, bufnr, 0, -1, { max_start_depth = 0, all = false }) do
local r = false
--- @cast match table<integer,TSNode>