diff options
author | actboy168 <actboy168@gmail.com> | 2020-12-02 20:39:49 +0800 |
---|---|---|
committer | actboy168 <actboy168@gmail.com> | 2020-12-02 20:39:49 +0800 |
commit | 9fe22ad2c924bc3f6fb8c73a3301ccfeddf72c9b (patch) | |
tree | e304c5ec10eb4f38ffed2a48d6436f0f9fdeeee8 /test/type_inference | |
parent | bf5d9d2159d5eabbd47e262941d46928f67b0b4e (diff) | |
parent | 8f5946edf67ab5de910ac1955337f8588be24406 (diff) | |
download | lua-language-server-9fe22ad2c924bc3f6fb8c73a3301ccfeddf72c9b.zip |
Merge branch 'master' of https://github.com/sumneko/lua-language-server
Diffstat (limited to 'test/type_inference')
-rw-r--r-- | test/type_inference/init.lua | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/type_inference/init.lua b/test/type_inference/init.lua index 40831c07..84462da6 100644 --- a/test/type_inference/init.lua +++ b/test/type_inference/init.lua @@ -329,3 +329,16 @@ local <?x?> TEST 'table' [[ self.<?t?>[#self.t+1] = {} ]] + +TEST 'string' [[ +---@type string[] +local x +local <?y?> = x[1] +]] + +TEST 'string' [[ +---@return string[] +local function f() end +local x = f() +local <?y?> = x[1] +]] |