blob: a75beba349936a43f9133e7d7184bad055deabcf [file] [log] [blame]
// |jit-test| allow-oom; allow-unhandlable-oom
if (!("oomAtAllocation" in this && "resetOOMFailure" in this))
quit();
function oomTest(f) {
var i = 1;
do {
try {
oomAtAllocation(i);
f();
} catch (e) {
more = resetOOMFailure();
}
i++;
} while(more);
}
oomTest(
() => 3
| (function () {
"use strict";
return eval("f();");
})()
);