summaryrefslogtreecommitdiff
path: root/server/src
diff options
context:
space:
mode:
Diffstat (limited to 'server/src')
-rw-r--r--server/src/core/definition.lua12
1 files changed, 12 insertions, 0 deletions
diff --git a/server/src/core/definition.lua b/server/src/core/definition.lua
index 21fd7f96..60964676 100644
--- a/server/src/core/definition.lua
+++ b/server/src/core/definition.lua
@@ -125,6 +125,15 @@ local function parseResultAsVar(vm, result, lsp)
return positions
end
+local function parseLocal(vm, loc, lsp)
+ local positions = {}
+ positions[#positions+1] = {
+ loc.source.start,
+ loc.source.finish,
+ }
+ return positions
+end
+
local function parseValue(vm, value, lsp)
local positions = {}
value:eachInfo(function (info)
@@ -142,6 +151,9 @@ return function (vm, source, lsp)
if not source then
return nil
end
+ if source:bindLocal() then
+ return parseLocal(vm, source:bindLocal(), lsp)
+ end
if source:bindValue() then
return parseValue(vm, source:bindValue(), lsp)
end