summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2021-07-06 19:49:48 +0800
committer最萌小汐 <sumneko@hotmail.com>2021-07-06 19:49:48 +0800
commit7baec4ad875f319ae6076788d656d42c42f47649 (patch)
treef6028803b7b913ffcadb8e6dd729a3540da47c59 /test
parent47f611c9c71bebe0f2ec0b9a52b3c578a1b8e01e (diff)
downloadlua-language-server-7baec4ad875f319ae6076788d656d42c42f47649.zip
fix infer when `__index` is a function
Diffstat (limited to 'test')
-rw-r--r--test/type_inference/init.lua4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/type_inference/init.lua b/test/type_inference/init.lua
index 83e73487..c07074f7 100644
--- a/test/type_inference/init.lua
+++ b/test/type_inference/init.lua
@@ -878,3 +878,7 @@ local t = f('')
print(t.<?x?>)
]]
+
+TEST 'table' [[
+local <?t?> = setmetatable({}, { __index = function () end })
+]]