diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/diagnostics/common.lua | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/test/diagnostics/common.lua b/test/diagnostics/common.lua index b91380b8..89537771 100644 --- a/test/diagnostics/common.lua +++ b/test/diagnostics/common.lua @@ -2231,3 +2231,34 @@ mt.init = function () obj.x = 1 end ]] + +TEST [[ +---@class A +X = {} + +function <!X.f!>() end + +function <!X.f!>() end +]] + +TEST [[ +---@meta + +---@class A +X = {} + +function X.f() end + +function X.f() end +]] + +TEST [[ +---@class A +X = {} + +if true then + function X.f() end +else + function X.f() end +end +]] |