blob: 7914b26519593ddc4311de5f154421c226fe3eb1 [file] [log] [blame]
function test() {
var a = {}, b = {}, c = {};
var passed = 0;
a[Symbol.toPrimitive] = function(hint) { passed += hint === "number"; return 0; };
b[Symbol.toPrimitive] = function(hint) { passed += hint === "string"; return 0; };
c[Symbol.toPrimitive] = function(hint) { passed += hint === "default"; return 0; };
a >= 0;
b in {};
c == 0;
return passed === 3;
}
if (!test())
throw new Error("Test failed");