summaryrefslogtreecommitdiff
path: root/server/src
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2019-03-18 17:34:40 +0800
committer最萌小汐 <sumneko@hotmail.com>2019-03-18 17:34:40 +0800
commit5da8740d528b6f20e969a5b2f5fbd7679e3d267d (patch)
tree2a925fc4e6f20b0af54db4a66dabfc751864444c /server/src
parente238ca2634dd5276a910967712773a0bc3eb7a02 (diff)
downloadlua-language-server-5da8740d528b6f20e969a5b2f5fbd7679e3d267d.zip
优化
Diffstat (limited to 'server/src')
-rw-r--r--server/src/vm/value.lua4
1 files changed, 4 insertions, 0 deletions
diff --git a/server/src/vm/value.lua b/server/src/vm/value.lua
index a1ee897b..9b33afe1 100644
--- a/server/src/vm/value.lua
+++ b/server/src/vm/value.lua
@@ -39,6 +39,10 @@ local function create (tp, source, literal)
end
local function isDeadChild(value, index)
+ local child = value._child[index]
+ if not child:getSource() then
+ return true
+ end
for srcId, info in pairs(value._info) do
local src = sourceMgr.list[srcId]
if src