summaryrefslogtreecommitdiff
path: root/script/core
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2021-07-14 16:59:24 +0800
committer最萌小汐 <sumneko@hotmail.com>2021-07-14 16:59:24 +0800
commit826175b57368d6daace55cec051aba2aba8ab019 (patch)
treeae8e26eab9c0c4fec06dbc3d88d0ba28d28ebe5a /script/core
parent4ddea4e9386ab0b0ec9583e6c468b52a0d7a8958 (diff)
downloadlua-language-server-826175b57368d6daace55cec051aba2aba8ab019.zip
fix #597
Diffstat (limited to 'script/core')
-rw-r--r--script/core/noder.lua8
1 files changed, 5 insertions, 3 deletions
diff --git a/script/core/noder.lua b/script/core/noder.lua
index 28a547bb..566a7445 100644
--- a/script/core/noder.lua
+++ b/script/core/noder.lua
@@ -1009,9 +1009,11 @@ function m.compileNode(noders, source)
end
end
if doc.type == 'doc.vararg' then
- for _, param in ipairs(source.args) do
- if param.type == '...' then
- pushForward(noders, getID(param), getID(doc))
+ if source.args then
+ for _, param in ipairs(source.args) do
+ if param.type == '...' then
+ pushForward(noders, getID(param), getID(doc))
+ end
end
end
end