Skip to content

Commit e4452f7

Browse files
committed
more test coverage
1 parent 030ee45 commit e4452f7

1 file changed

Lines changed: 17 additions & 0 deletions

File tree

test/tests/nattlua/analyzer/analyzer.lua

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -689,3 +689,20 @@ end
689689
690690
attest.equal(test()[2], 2)
691691
]]
692+
analyze[[
693+
local x = setmetatable({}, {
694+
__unm = function(self: any)
695+
return 42
696+
end,
697+
__bxor = function(self: any)
698+
return 43
699+
end,
700+
__len = function(self: any)
701+
return 44
702+
end,
703+
})
704+
705+
attest.equal(-x, 42)
706+
attest.equal(~x, 43)
707+
attest.equal(#x, 44)
708+
]]

0 commit comments

Comments
 (0)