Changeset 258976 in webkit
- Timestamp:
- Mar 25, 2020 4:11:47 AM (4 years ago)
- Location:
- trunk
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JSTests/ChangeLog
r258965 r258976 1 2020-03-25 Alexey Shvayka <shvaikalesh@gmail.com> 2 3 \b escapes inside character classes should be valid in Unicode patterns 4 https://bugs.webkit.org/show_bug.cgi?id=209528 5 6 Reviewed by Darin Adler. 7 8 * test262/expectations.yaml: Mark 2 test cases as passing. 9 1 10 2020-03-24 Tadeu Zagallo <tzagallo@apple.com> 2 11 -
trunk/JSTests/test262/expectations.yaml
r258963 r258976 1712 1712 default: 'SyntaxError: Invalid regular expression: number too large in {} quantifier' 1713 1713 strict mode: 'SyntaxError: Invalid regular expression: number too large in {} quantifier' 1714 test/built-ins/RegExp/unicode_character_class_backspace_escape.js:1715 default: 'SyntaxError: Invalid regular expression: invalid escaped character for Unicode pattern'1716 strict mode: 'SyntaxError: Invalid regular expression: invalid escaped character for Unicode pattern'1717 1714 test/built-ins/RegExp/unicode_restricted_identity_escape_alpha.js: 1718 1715 default: "Test262Error: IdentityEscape in AtomEscape: 'k' Expected a SyntaxError to be thrown but no exception was thrown at all" -
trunk/LayoutTests/ChangeLog
r258967 r258976 1 2020-03-25 Alexey Shvayka <shvaikalesh@gmail.com> 2 3 \b escapes inside character classes should be valid in Unicode patterns 4 https://bugs.webkit.org/show_bug.cgi?id=209528 5 6 Reviewed by Darin Adler. 7 8 * js/regexp-unicode-expected.txt: 9 * js/script-tests/regexp-unicode.js: 10 1 11 2020-03-24 Zalan Bujtas <zalan@apple.com> 2 12 -
trunk/LayoutTests/js/regexp-unicode-expected.txt
r255975 r258976 188 188 PASS r = new RegExp("\\a", "u") threw exception SyntaxError: Invalid regular expression: invalid escaped character for Unicode pattern. 189 189 PASS r = new RegExp("[\\a]", "u") threw exception SyntaxError: Invalid regular expression: invalid escaped character for Unicode pattern. 190 PASS r = new RegExp("[\\b]", "u") threw exception SyntaxError: Invalid regular expression: invalid escaped character for Unicode pattern.191 190 PASS r = new RegExp("[\\B]", "u") threw exception SyntaxError: Invalid regular expression: invalid escaped character for Unicode pattern. 192 191 PASS r = new RegExp("\\x", "u") threw exception SyntaxError: Invalid regular expression: invalid escaped character for Unicode pattern. -
trunk/LayoutTests/js/script-tests/regexp-unicode.js
r255975 r258976 248 248 shouldThrowInvalidEscape("\\\\a"); 249 249 shouldThrowInvalidEscape("[\\\\a]"); 250 shouldThrowInvalidEscape("[\\\\b]");251 250 shouldThrowInvalidEscape("[\\\\B]"); 252 251 shouldThrowInvalidEscape("\\\\x"); -
trunk/Source/JavaScriptCore/ChangeLog
r258968 r258976 1 2020-03-25 Alexey Shvayka <shvaikalesh@gmail.com> 2 3 \b escapes inside character classes should be valid in Unicode patterns 4 https://bugs.webkit.org/show_bug.cgi?id=209528 5 6 Reviewed by Darin Adler. 7 8 This change removes isIdentityEscapeAnError('b') check, allowing \b escapes 9 inside character classes in Unicode patterns match U+0008 (BACKSPACE) characters, 10 aligning JSC with V8 and SpiderMonkey. 11 12 Grammar: https://tc39.es/ecma262/#prod-ClassEscape 13 ('b' comes before CharacterEscape :: IdentityEscape) 14 15 * yarr/YarrParser.h: 16 (JSC::Yarr::Parser::parseEscape): 17 1 18 2020-03-24 Ross Kirsling <ross.kirsling@sony.com> 2 19 -
trunk/Source/JavaScriptCore/yarr/YarrParser.h
r255689 r258976 276 276 case 'b': 277 277 consume(); 278 if (inCharacterClass) { 279 if (isIdentityEscapeAnError('b')) 280 break; 281 278 if (inCharacterClass) 282 279 delegate.atomPatternCharacter('\b'); 283 }else {280 else { 284 281 delegate.assertionWordBoundary(false); 285 282 return false;
Note: See TracChangeset
for help on using the changeset viewer.