diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/type_inference/init.lua | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/type_inference/init.lua b/test/type_inference/init.lua index 0a19082a..5ed572dd 100644 --- a/test/type_inference/init.lua +++ b/test/type_inference/init.lua @@ -2548,3 +2548,14 @@ while <?t?> ~= nil do print(t) end ]] + +TEST 'integer' [[ +---@type integer? +local n + +if not n then + error('n is nil') +end + +print(<?n?>) +]] |