diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2018-12-24 15:35:25 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2018-12-24 15:35:25 +0800 |
commit | 622bb5db85d7ed453295f1c4df463532075a695b (patch) | |
tree | 1dbefb8a183dd0cbe988c2988e7081fd870bb365 /server | |
parent | 83b82470f1486493e5373501f1f69d8ca0b6e18f (diff) | |
download | lua-language-server-622bb5db85d7ed453295f1c4df463532075a695b.zip |
判空
Diffstat (limited to 'server')
-rw-r--r-- | server/src/matcher/vm.lua | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/server/src/matcher/vm.lua b/server/src/matcher/vm.lua index d80aaba2..1aaffac4 100644 --- a/server/src/matcher/vm.lua +++ b/server/src/matcher/vm.lua @@ -809,6 +809,9 @@ function mt:unpackList(list, expect) local res = { type = 'list', } + if not list then + return res + end if list.type == 'list' or list.type == 'call' then for i, exp in ipairs(list) do if exp.type == '...' then |