File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -365,8 +365,6 @@ export function hashString53Bit(str: string, seed: number = 0): number {
365365 * @return {string } The string with the escape characters converted to their escape character form.
366366 */
367367export function convertStringVersionOfEscapeCharactersToEscapeCharacters ( val : string ) : string {
368- // replace string version of backspace character with the actual backspace character
369- val = val . replaceAll ( '\\b' , '\b' ) ;
370368 // replace string version of form feed character with the actual form feed character
371369 val = val . replaceAll ( '\\f' , '\f' ) ;
372370 // replace string version of new line character with the actual new line character
@@ -377,6 +375,8 @@ export function convertStringVersionOfEscapeCharactersToEscapeCharacters(val: st
377375 val = val . replaceAll ( '\\t' , '\t' ) ;
378376 // replace string version of vertical tab character with the actual vertical tab character
379377 val = val . replaceAll ( '\\v' , '\v' ) ;
378+ // replace string version of escaped \ with the single instance of \
379+ val = val . replaceAll ( '\\\\' , '\\' ) ;
380380
381381 return val ;
382382}
You can’t perform that action at this time.
0 commit comments