diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2019-11-27 17:32:15 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2019-11-27 17:32:15 +0800 |
commit | aeeb7d9a52ca429bfd4db41a1e675261d285665c (patch) | |
tree | b6a4b09db417eb9aa1b9405cd508af8d3c484aa2 /script-beta/vm | |
parent | 4b4b29fae0fee6cf109be4400104d23b191d24fd (diff) | |
download | lua-language-server-aeeb7d9a52ca429bfd4db41a1e675261d285665c.zip |
修正报错
Diffstat (limited to 'script-beta/vm')
-rw-r--r-- | script-beta/vm/getValue.lua | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/script-beta/vm/getValue.lua b/script-beta/vm/getValue.lua index ee486a54..30fd00aa 100644 --- a/script-beta/vm/getValue.lua +++ b/script-beta/vm/getValue.lua @@ -1,4 +1,5 @@ local vm = require 'vm.vm' +local util = require 'utility' local typeSort = { ['boolean'] = 1, @@ -563,6 +564,12 @@ local function checkLibraryReturn(source) if not rtn then return nil end + if not rtn.type then + return nil + end + if rtn.type == '...' then + return + end return alloc { type = rtn.type, value = rtn.value, @@ -598,6 +605,9 @@ local function checkLibraryArg(source) if not arg then return end + if not arg.type then + return + end if arg.type == '...' then return end |