summaryrefslogtreecommitdiff
path: root/server/src/core
diff options
context:
space:
mode:
Diffstat (limited to 'server/src/core')
-rw-r--r--server/src/core/vm.lua2
1 files changed, 2 insertions, 0 deletions
diff --git a/server/src/core/vm.lua b/server/src/core/vm.lua
index 5ccada8e..fc00b581 100644
--- a/server/src/core/vm.lua
+++ b/server/src/core/vm.lua
@@ -119,6 +119,7 @@ function mt:createLocal(key, source, value)
self.scope.locals[key] = loc
self.results.locals[#self.results.locals+1] = loc
+ self.chunk.locals[#self.chunk.locals+1] = loc
self:addInfo(loc, 'local', source)
self:setValue(loc, value, source)
@@ -1463,6 +1464,7 @@ local function compile(ast, lsp, uri)
},
chunk = env {
labels = {},
+ locals = {},
},
results = {
locals = {},