summaryrefslogtreecommitdiff
path: root/test/type_inference
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2023-08-10 16:23:01 +0800
committer最萌小汐 <sumneko@hotmail.com>2023-08-10 16:23:01 +0800
commitc3c73efb8fbb3e37d0191d3f924283861218a358 (patch)
treefe449ebf84ac56cd9a8928adba04093126997830 /test/type_inference
parentb778d586096ecfe40832ebf8fd3d795a3d4947dc (diff)
downloadlua-language-server-c3c73efb8fbb3e37d0191d3f924283861218a358.zip
enable `as` table
#2144
Diffstat (limited to 'test/type_inference')
-rw-r--r--test/type_inference/init.lua8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/type_inference/init.lua b/test/type_inference/init.lua
index 8797cfdd..9f5c8493 100644
--- a/test/type_inference/init.lua
+++ b/test/type_inference/init.lua
@@ -4313,3 +4313,11 @@ local x = 1
repeat
until <?x?>
]]
+
+TEST 'A' [=[
+local function f()
+ return {} --[[@as A]]
+end
+
+local <?x?> = f()
+]=]