summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/regexp/bug1640479.js
blob: a04b44a2a343ad50accf5326b4c658999b2744b1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
var failures = 0;
var i = 0;

function foo() {
    var e;
    var r = RegExp("(?<_" + (i++) + "a>)");
    try { e = r.exec("a"); } catch {}
    e = r.exec("a");
    if (e.groups === undefined) failures++;
}

oomTest(foo);
assertEq(failures, 0);