diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2022-07-08 17:31:40 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2022-07-08 17:31:40 +0800 |
commit | 103aee69bf717936432e2739695305ce2058786e (patch) | |
tree | 16dc53cecd38bb234b5caa01f3035da9893ca165 /script/vm/compiler.lua | |
parent | 7c29a6012bf5fe2cc1ff79598f8be6f80528e767 (diff) | |
download | lua-language-server-103aee69bf717936432e2739695305ce2058786e.zip |
cleanup
Diffstat (limited to 'script/vm/compiler.lua')
-rw-r--r-- | script/vm/compiler.lua | 21 |
1 files changed, 5 insertions, 16 deletions
diff --git a/script/vm/compiler.lua b/script/vm/compiler.lua index cda85392..684ad9d0 100644 --- a/script/vm/compiler.lua +++ b/script/vm/compiler.lua @@ -22,24 +22,15 @@ local function bindDocs(source) if not docs then return false end - local isParam = source.parent.type == 'funcargs' - or (source.parent.type == 'in' and source.finish <= source.parent.keys.finish) for i = #docs, 1, -1 do local doc = docs[i] if doc.type == 'doc.type' then - if not isParam then - vm.setNode(source, vm.compileNode(doc)) - return true - end + vm.setNode(source, vm.compileNode(doc)) + return true end if doc.type == 'doc.class' then - if (source.type == 'local' and not isParam) - or (source._globalNode and guide.isSet(source)) - or source.type == 'tablefield' - or source.type == 'tableindex' then - vm.setNode(source, vm.compileNode(doc)) - return true - end + vm.setNode(source, vm.compileNode(doc)) + return true end if doc.type == 'doc.param' then local node = vm.compileNode(doc) @@ -67,9 +58,7 @@ local function bindDocs(source) return true end if doc.type == 'doc.overload' then - if not isParam then - vm.setNode(source, vm.compileNode(doc)) - end + vm.setNode(source, vm.compileNode(doc)) end end return false |