Wed, 31 Dec 2014 07:53:36 +0100
Correct small whitespace inconsistency, lost while renaming variables.
michael@0 | 1 | /* Capture group reset to undefined during second iteration, so backreference doesn't see prior result. */ |
michael@0 | 2 | var re = /(?:^(a)|\1(a)|(ab)){2}/; |
michael@0 | 3 | var str = 'aab'; |
michael@0 | 4 | var actual = re.exec(str); |
michael@0 | 5 | var expected = makeExpectedMatch(['aa', undefined, 'a', undefined], 0, str); |
michael@0 | 6 | checkRegExpMatch(actual, expected); |
michael@0 | 7 | |
michael@0 | 8 | if (typeof reportCompare === 'function') |
michael@0 | 9 | reportCompare(true, true); |