summaryrefslogtreecommitdiff
path: root/script/core/implementation.lua
diff options
context:
space:
mode:
Diffstat (limited to 'script/core/implementation.lua')
-rw-r--r--script/core/implementation.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/script/core/implementation.lua b/script/core/implementation.lua
index da4d4c8b..e48e2f73 100644
--- a/script/core/implementation.lua
+++ b/script/core/implementation.lua
@@ -78,6 +78,7 @@ local function convertIndex(source)
return source
end
+---@async
return function (uri, offset)
local ast = files.getState(uri)
if not ast then
@@ -91,9 +92,12 @@ return function (uri, offset)
local results = {}
- local defs = vm.getDefs(source)
+ local defs = vm.getRefs(source)
for _, src in ipairs(defs) do
+ if not guide.isAssign(src) then
+ goto CONTINUE
+ end
if src.type == 'global' then
goto CONTINUE
end