summaryrefslogtreecommitdiff
path: root/test/type_inference/init.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2022-06-15 01:29:21 +0800
committer最萌小汐 <sumneko@hotmail.com>2022-06-15 01:29:21 +0800
commit738f3410ed8dd2b6c5203fd984d5966d510a1d79 (patch)
treeeced293a1e56f3729388338d57dff6b6ccac0a37 /test/type_inference/init.lua
parent767db22f89459bad7e466d0e467f72f43f0c2046 (diff)
downloadlua-language-server-738f3410ed8dd2b6c5203fd984d5966d510a1d79.zip
#1208 avoid dead cycles
Diffstat (limited to 'test/type_inference/init.lua')
-rw-r--r--test/type_inference/init.lua21
1 files changed, 21 insertions, 0 deletions
diff --git a/test/type_inference/init.lua b/test/type_inference/init.lua
index efcc5fea..ecc22a3f 100644
--- a/test/type_inference/init.lua
+++ b/test/type_inference/init.lua
@@ -2491,3 +2491,24 @@ end
print(<?x?>)
]]
+
+TEST 'table<unknown, true>' [[
+---@alias xxx table<xxx, true>
+
+---@type xxx
+local <?t?>
+]]
+
+TEST 'unknown[][]' [[
+---@alias xxx xxx[]
+
+---@type xxx
+local <?t?>
+]]
+
+TEST 'fun(x: fun(x: unknown))' [[
+---@alias xxx fun(x: xxx)
+
+---@type xxx
+local <?t?>
+]]