summaryrefslogtreecommitdiff
path: root/script/vm/generic.lua
diff options
context:
space:
mode:
authorAlexCai2019 <89138532+AlexCai2019@users.noreply.github.com>2022-05-08 01:43:28 +0800
committerGitHub <noreply@github.com>2022-05-08 01:43:28 +0800
commit0fd83c4ca9f82a02becab6c304a8a7de75098507 (patch)
treebe9790d9d4823fe728c5b36e94093fe5f42b7725 /script/vm/generic.lua
parent89203efad8c9b5513e05ca4d5696107924865b10 (diff)
parent67b4c574849d1667e0ecb39c51aeed8e30b43056 (diff)
downloadlua-language-server-0fd83c4ca9f82a02becab6c304a8a7de75098507.zip
Merge branch 'sumneko:master' into master
Diffstat (limited to 'script/vm/generic.lua')
-rw-r--r--script/vm/generic.lua5
1 files changed, 3 insertions, 2 deletions
diff --git a/script/vm/generic.lua b/script/vm/generic.lua
index b3981ff8..6462028e 100644
--- a/script/vm/generic.lua
+++ b/script/vm/generic.lua
@@ -1,3 +1,4 @@
+---@class vm
local vm = require 'vm.vm'
---@class parser.object
@@ -114,7 +115,7 @@ end
---@param uri uri
---@param args parser.object
----@return parser.object
+---@return vm.node
function mt:resolve(uri, args)
local resolved = self.sign:resolve(uri, args)
local protoNode = vm.compileNode(self.proto)
@@ -129,7 +130,7 @@ end
---@param proto vm.object
---@param sign vm.sign
---@return vm.generic
-return function (proto, sign)
+function vm.createGeneric(proto, sign)
local generic = setmetatable({
sign = sign,
proto = proto,