1 2 3 4 5 6 7 8 9 10 11
function testSlowNativeBail() { var a = ['0', '1', '2', '3', '+']; try { for (var i = 0; i < a.length; i++) new RegExp(a[i]); assertEq(true, false); } catch (exc) { assertEq(exc instanceof SyntaxError, true); } } testSlowNativeBail();