blob: 72bffb31b7f6151d6a3a9c441464323adad15ad5 [file] [log] [blame]
//@ skip if $hostOS != "darwin" or $architecture != "x86-64"
//@ runDefault("--disableOptionsFreezingForTesting")
//@ slow!
function foo() {
class C {
constructor(func) {
this.func = func;
}
runTest() {
this.func();
}
}
function recurseAndTest() {
try {
recurseAndTest();
test.runTest();
} catch (e) {
}
}
const howManyParentheses = 1000;
const deepRE = new RegExp('('.repeat(howManyParentheses) + ')'.repeat(howManyParentheses));
let test =
new C(() => {
deepRE.exec('');
});
recurseAndTest();
}
$vm.callWithStackSize(foo, 100*1024)