summaryrefslogtreecommitdiff
path: root/server
diff options
context:
space:
mode:
authorsumneko <sumneko@hotmail.com>2019-04-09 19:04:08 +0800
committersumneko <sumneko@hotmail.com>2019-04-09 19:04:08 +0800
commit4fe47715dacfb18e79848a55f4e1b4d2607b0efd (patch)
tree34c33da689a6f559b9c47aa0856062b701853133 /server
parent70441948891e7d9d5c2cde9bb81b095b529e4d72 (diff)
downloadlua-language-server-4fe47715dacfb18e79848a55f4e1b4d2607b0efd.zip
xpcall 的差异
Diffstat (limited to 'server')
-rw-r--r--server/libs/@lua/basic.lni17
-rw-r--r--server/locale/en-US/libs/@lua/basic.lni5
-rw-r--r--server/locale/zh-CN/libs/@lua/basic.lni3
3 files changed, 24 insertions, 1 deletions
diff --git a/server/libs/@lua/basic.lni b/server/libs/@lua/basic.lni
index 13cf51a6..85d5d6da 100644
--- a/server/libs/@lua/basic.lni
+++ b/server/libs/@lua/basic.lni
@@ -541,6 +541,23 @@ name = 'result'
``````````
type = '...'
+['xpcall Lua 5.1']
+name = 'xpcall'
+version = 'Lua 5.1'
+[[.args]]
+name = 'f'
+type = 'function'
+``````````
+name = 'err'
+type = 'function'
+[[.returns]]
+name = 'success'
+type = 'boolean'
+``````````
+name = 'result'
+``````````
+type = '...'
+
[require]
special = 'require'
[[.args]]
diff --git a/server/locale/en-US/libs/@lua/basic.lni b/server/locale/en-US/libs/@lua/basic.lni
index 6a391cac..e7068c7e 100644
--- a/server/locale/en-US/libs/@lua/basic.lni
+++ b/server/locale/en-US/libs/@lua/basic.lni
@@ -224,7 +224,10 @@ The default for `tocont` is false.
]]
[xpcall]
-description = 'Calls function f with the given arguments in protected mode with a new message handler.'
+description = 'Calls function `f` with the given arguments in protected mode with a new message handler.'
+
+['xpcall Lua 5.1']
+description = 'Calls function `f` in protected mode with a new message handler.'
[require]
description = 'Loads the given module.'
diff --git a/server/locale/zh-CN/libs/@lua/basic.lni b/server/locale/zh-CN/libs/@lua/basic.lni
index 50124adf..183983e4 100644
--- a/server/locale/zh-CN/libs/@lua/basic.lni
+++ b/server/locale/zh-CN/libs/@lua/basic.lni
@@ -221,6 +221,9 @@ description = '以给定消息发出一个警告。当`tocont`为 true 时,应
[xpcall]
description = '传入参数并设置一个消息处理器 `msgh`,以 *保护模式* 调用函数 `f` 。'
+['xpcall Lua 5.1']
+description = '设置一个消息处理器 `err`,以 *保护模式* 调用函数 `f` 。'
+
[require]
description = '加载一个模块。'