summaryrefslogtreecommitdiff
path: root/script-beta/vm/getClass.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2020-09-07 15:32:57 +0800
committer最萌小汐 <sumneko@hotmail.com>2020-09-07 15:32:57 +0800
commitb4c327778810b0a34e5abe26508a91ddfffd45e6 (patch)
tree57bb15e5881d78a697c626c88bb880bbcadc8d8c /script-beta/vm/getClass.lua
parentbf5578f46a2c59ba8a2d031cdba3c9ecfc092e11 (diff)
downloadlua-language-server-b4c327778810b0a34e5abe26508a91ddfffd45e6.zip
library跟进
Diffstat (limited to 'script-beta/vm/getClass.lua')
-rw-r--r--script-beta/vm/getClass.lua5
1 files changed, 5 insertions, 0 deletions
diff --git a/script-beta/vm/getClass.lua b/script-beta/vm/getClass.lua
index b573c6be..c8eb2080 100644
--- a/script-beta/vm/getClass.lua
+++ b/script-beta/vm/getClass.lua
@@ -2,6 +2,11 @@ local vm = require 'vm.vm'
local guide = require 'parser.guide'
local function getClass(source, classes, deep)
+ local lib = vm.getLibrary(source)
+ if lib then
+ classes[#classes+1] = lib.name
+ return
+ end
if deep > 3 then
return
end