diff options
Diffstat (limited to 'test/type_inference')
-rw-r--r-- | test/type_inference/init.lua | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/type_inference/init.lua b/test/type_inference/init.lua index 0eb43ed3..b8ca4df9 100644 --- a/test/type_inference/init.lua +++ b/test/type_inference/init.lua @@ -4060,3 +4060,17 @@ local m, v local <?r?> = m * v ]] + +TEST 'A|B' [[ +---@class A +---@class B + +---@type A|B +local t + +if x then + ---@cast t A +else + print(<?t?>) +end +]] |