mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-14 09:20:04 -04:00
Fix find_usages
This commit is contained in:
parent
cc908cfcd7
commit
ce4adf11cf
1 changed files with 1 additions and 0 deletions
|
|
@ -254,6 +254,7 @@ function M.find_usages(node, scope_node, bufnr)
|
||||||
local usages = {}
|
local usages = {}
|
||||||
|
|
||||||
for match in M.iter_locals(bufnr, scope_node) do
|
for match in M.iter_locals(bufnr, scope_node) do
|
||||||
|
match = match["local"]
|
||||||
if match.reference and match.reference.node and ts.get_node_text(match.reference.node, bufnr) == node_text then
|
if match.reference and match.reference.node and ts.get_node_text(match.reference.node, bufnr) == node_text then
|
||||||
local def_node, _, kind = M.find_definition(match.reference.node, bufnr)
|
local def_node, _, kind = M.find_definition(match.reference.node, bufnr)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue