diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2019-06-28 15:47:48 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2019-06-28 15:47:48 +0800 |
commit | ef00d018e5f3292dd08deeeabfc77e6c75492a67 (patch) | |
tree | aa1e4500d9e122027762935721c1adbc59cfc45d /server/meta | |
parent | daee93fb17e8f206e63ab8573566762011a3f1cd (diff) | |
download | lua-language-server-ef00d018e5f3292dd08deeeabfc77e6c75492a67.zip |
支持返回值命名
Diffstat (limited to 'server/meta')
-rw-r--r-- | server/meta/Lua 5.4/basic.lua | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/server/meta/Lua 5.4/basic.lua b/server/meta/Lua 5.4/basic.lua index 9c301c72..23d87cdb 100644 --- a/server/meta/Lua 5.4/basic.lua +++ b/server/meta/Lua 5.4/basic.lua @@ -31,7 +31,15 @@ end --- 当前解释器版本号。 _VERSION = 'Lua 5.4' -local next = next +--- 返回该键的下一个键及其关联的值。 +---@param t table +---@param index any {optional = 'self'} +---@return any {name = 'key'} +---@return any {name = 'value'} +local function next(t, index) +end + +_G['next'] = next --- 能迭代表 `t` 中的所有键值对。 ---|```lua |