| OLD | NEW |
| (Empty) |
| 1 Tests that regular expressions do not have extensions that diverge from the Java
Script specification. Because WebKit originally used a copy of PCRE, various non
-JavaScript regular expression features were historically present. Also tests va
rious related edge cases. | |
| 2 | |
| 3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". | |
| 4 | |
| 5 | |
| 6 PASS /\x{41}/.exec("yA1") is null | |
| 7 PASS /[\x{41}]/.exec("yA1").toString() is "1" | |
| 8 PASS /\x1g/.exec("x1g").toString() is "x1g" | |
| 9 PASS /[\x1g]/.exec("x").toString() is "x" | |
| 10 PASS /[\x1g]/.exec("1").toString() is "1" | |
| 11 PASS /\2147483648/.exec(String.fromCharCode(140) + "7483648").toString() is Stri
ng.fromCharCode(140) + "7483648" | |
| 12 PASS /\4294967296/.exec("\"94967296").toString() is "\"94967296" | |
| 13 FAIL /\8589934592/.exec("\\8589934592").toString() should be \8589934592. Was 85
89934592. | |
| 14 PASS "\nAbc\n".replace(/(\n)[^\n]+$/, "$1") is "\nAbc\n" | |
| 15 PASS /x$/.exec("x\n") is null | |
| 16 PASS /x++/ threw exception SyntaxError: Invalid regular expression: /x++/: Nothi
ng to repeat. | |
| 17 PASS /[]]/.exec("]") is null | |
| 18 | |
| 19 Octal escape sequences are in Annex B of the standard. | |
| 20 | |
| 21 PASS /\060/.exec("y01").toString() is "0" | |
| 22 PASS /[\060]/.exec("y01").toString() is "0" | |
| 23 PASS /\606/.exec("y06").toString() is "06" | |
| 24 PASS /[\606]/.exec("y06").toString() is "0" | |
| 25 PASS /[\606]/.exec("y6").toString() is "6" | |
| 26 PASS /\101/.exec("yA1").toString() is "A" | |
| 27 PASS /[\101]/.exec("yA1").toString() is "A" | |
| 28 PASS /\1011/.exec("yA1").toString() is "A1" | |
| 29 PASS /[\1011]/.exec("yA1").toString() is "A" | |
| 30 PASS /[\1011]/.exec("y1").toString() is "1" | |
| 31 PASS /\10q/.exec("y" + String.fromCharCode(8) + "q").toString() is String.fromCh
arCode(8) + "q" | |
| 32 PASS /[\10q]/.exec("y" + String.fromCharCode(8) + "q").toString() is String.from
CharCode(8) | |
| 33 PASS /\1q/.exec("y" + String.fromCharCode(1) + "q").toString() is String.fromCha
rCode(1) + "q" | |
| 34 PASS /[\1q]/.exec("y" + String.fromCharCode(1) + "q").toString() is String.fromC
harCode(1) | |
| 35 PASS /[\1q]/.exec("yq").toString() is "q" | |
| 36 FAIL /\8q/.exec("\\8q").toString() should be \8q. Was 8q. | |
| 37 PASS /[\8q]/.exec("y8q").toString() is "8" | |
| 38 PASS /[\8q]/.exec("yq").toString() is "q" | |
| 39 PASS /(x)\1q/.exec("xxq").toString() is "xxq,x" | |
| 40 PASS /(x)[\1q]/.exec("xxq").toString() is "xq,x" | |
| 41 PASS /(x)[\1q]/.exec("xx" + String.fromCharCode(1)).toString() is "x" + String.f
romCharCode(1) + ",x" | |
| 42 | |
| 43 PASS successfullyParsed is true | |
| 44 | |
| 45 TEST COMPLETE | |
| 46 | |
| OLD | NEW |