summaryrefslogtreecommitdiff
path: root/server/src/core/completion.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2019-01-29 18:08:32 +0800
committer最萌小汐 <sumneko@hotmail.com>2019-01-29 18:08:32 +0800
commite155e1462e613d347195f950696c4ad511358123 (patch)
tree2036a9eaa8a473539650253c3f8f87738495df9d /server/src/core/completion.lua
parentbbdd2711dec66a90d712673acf1ff453581d1c51 (diff)
downloadlua-language-server-e155e1462e613d347195f950696c4ad511358123.zip
修正函数内定义的局部变量可能会失效的BUG
Diffstat (limited to 'server/src/core/completion.lua')
-rw-r--r--server/src/core/completion.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/server/src/core/completion.lua b/server/src/core/completion.lua
index 685aa8d3..4d735d9d 100644
--- a/server/src/core/completion.lua
+++ b/server/src/core/completion.lua
@@ -103,6 +103,9 @@ local function searchLocals(vm, pos, name, callback)
if loc.source.start == 0 then
goto CONTINUE
end
+ if not loc.close then
+ log.debug('Miss loc close', table.dump(loc))
+ end
if loc.source.start <= pos and loc.close >= pos then
if matchKey(name, loc.key) then
callback(loc)