@ -105,7 +105,7 @@ function quote(s) {
. replace ( /\n/g , '\\n' ) // line feed
. replace ( /[\x80-\uFFFF]/g , escape ) // non-ASCII characters
+ '"' ;
} ;
}
/ *
* Escapes characters inside the string so that it can be used as a list of
@ -118,14 +118,14 @@ function quoteForRegexpClass(s) {
* For portability , we also escape escape all non - ASCII characters .
* /
return s
. replace ( /\\/g , '\\\\' ) // backslash
. replace ( /\0/g , '\\0' ) // null, IE needs this
. replace ( /\//g , '\\/' ) // closing slash
. replace ( /]/g , '\\]' ) // closing bracket
. replace ( /-/g , '\\-' ) // dash
. replace ( /\r/g , '\\r' ) // carriage return
. replace ( /\n/g , '\\n' ) // line feed
. replace ( /[\x80-\uFFFF]/g , escape ) // non-ASCII characters
. replace ( /\\/g , '\\\\' ) // backslash
. replace ( /\0/g , '\\0' ) // null, IE needs this
. replace ( /\//g , '\\/' ) // closing slash
. replace ( /]/g , '\\]' ) // closing bracket
. replace ( /-/g , '\\-' ) // dash
. replace ( /\r/g , '\\r' ) // carriage return
. replace ( /\n/g , '\\n' ) // line feed
. replace ( /[\x80-\uFFFF]/g , escape ) ; // non-ASCII characters
}
/ *
@ -137,5 +137,5 @@ function quoteForRegexpClass(s) {
function buildNodeVisitor ( functions ) {
return function ( node ) {
return functions [ node . type ] . apply ( null , arguments ) ;
}
} ;
}