blob: 12f24230c34414628be5ee2953f84af324107f8f [file] [log] [blame]
function Constructor(x) {}
Object.defineProperty(Constructor, Symbol.hasInstance, {value: function() { return false; }});
x = new Constructor();
function instanceOf(a, b) {
return a instanceof b;
}
noInline(instanceOf);
function body() {
var result = 0;
for (var i = 0; i < 100000; i++) {
if (instanceOf(x, Constructor))
result++;
}
return result;
}
noInline(body);
if (body())
throw "result incorrect";