File tree Expand file tree Collapse file tree 4 files changed +8
-1
lines changed
Expand file tree Collapse file tree 4 files changed +8
-1
lines changed Original file line number Diff line number Diff line change 1616- Fixed (updated following the final spec) one more case ` Set.prototype.difference ` polyfill with updating ` this `
1717- Fixed ` DataView.prototype.setFloat16 ` polyfill in (0, 1) range
1818- Fixed order of arguments validation in ` String.prototype.{ startsWith, endsWith } ` polyfills
19+ - Fixed some cases of chars case in ` escape ` polyfill
1920- Fixed named backreferences in ` RegExp ` NCG polyfill
2021- Fixed some cases of ` RegExp ` NCG polyfill in combination with other types of groups
2122- Fixed some cases of ` RegExp ` NCG polyfill in combination with ` dotAll `
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ $({ global: true }, {
3333 } else {
3434 code = charCodeAt ( chr , 0 ) ;
3535 if ( code < 256 ) {
36- result += '%' + hex ( code , 2 ) ;
36+ result += '%' + toUpperCase ( hex ( code , 2 ) ) ;
3737 } else {
3838 result += '%u' + toUpperCase ( hex ( code , 4 ) ) ;
3939 }
Original file line number Diff line number Diff line change @@ -4,6 +4,9 @@ QUnit.test('escape', assert => {
44 assert . arity ( escape , 1 ) ;
55 assert . looksNative ( escape ) ;
66 assert . same ( escape ( '!q2ф' ) , '%21q2%u0444' ) ;
7+ assert . same ( escape ( '\n' ) , '%0A' , 'percent encoding uses uppercase hex digits' ) ;
8+ assert . same ( escape ( '\u0001' ) , '%01' , 'low code points use uppercase hex' ) ;
9+ assert . same ( escape ( '\u00FF' ) , '%FF' , 'code < 256 uses uppercase hex' ) ;
710 assert . same ( escape ( null ) , 'null' ) ;
811 assert . same ( escape ( undefined ) , 'undefined' ) ;
912
Original file line number Diff line number Diff line change @@ -4,6 +4,9 @@ QUnit.test('escape', assert => {
44 assert . isFunction ( escape ) ;
55 assert . arity ( escape , 1 ) ;
66 assert . same ( escape ( '!q2ф' ) , '%21q2%u0444' ) ;
7+ assert . same ( escape ( '\n' ) , '%0A' , 'percent encoding uses uppercase hex digits' ) ;
8+ assert . same ( escape ( '\u0001' ) , '%01' , 'low code points use uppercase hex' ) ;
9+ assert . same ( escape ( '\u00FF' ) , '%FF' , 'code < 256 uses uppercase hex' ) ;
710 assert . same ( escape ( null ) , 'null' ) ;
811 assert . same ( escape ( undefined ) , 'undefined' ) ;
912
You can’t perform that action at this time.
0 commit comments