summaryrefslogtreecommitdiff
path: root/server/test
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2018-12-13 22:12:37 +0800
committer最萌小汐 <sumneko@hotmail.com>2018-12-13 22:12:37 +0800
commit352b6489551f0fe5b308cfc7de608dcec42a88ee (patch)
tree2f726395d2cf5e62113932ba2dc1ad8ee69f4496 /server/test
parent0a3e6482362eb35948cc0c744e089ff491104580 (diff)
downloadlua-language-server-352b6489551f0fe5b308cfc7de608dcec42a88ee.zip
可以从自定义函数中推断参数类型了
Diffstat (limited to 'server/test')
-rw-r--r--server/test/type_inference/init.lua8
1 files changed, 8 insertions, 0 deletions
diff --git a/server/test/type_inference/init.lua b/server/test/type_inference/init.lua
index 733fd99a..33e368ea 100644
--- a/server/test/type_inference/init.lua
+++ b/server/test/type_inference/init.lua
@@ -150,3 +150,11 @@ x(1)
TEST 'table' [[
setmetatable(<?b?>)
]]
+
+TEST 'number' [[
+local function x(a)
+ _ = a + 1
+end
+local b
+x(<?b?>)
+]]