blob: 2d0d46595f23040de438d4087ce328ec810da6cb [file] [log] [blame]
function shouldBe(actual, expected) {
if (actual !== expected)
throw new Error(`bad value: ${String(actual)}`);
}
var boundFunction = function(){}.bind();
Object.defineProperty(boundFunction, "prototype", {
value: Array.prototype
});
var result = Reflect.construct(Array, [], boundFunction);
shouldBe(result.__proto__, Array.prototype);