MCPcopy Create free account
hub / github.com/socketstream/socketstream / encodeEscape

Function encodeEscape

docs/js/google-code-prettify.js:284–291  ·  view source on GitHub ↗
(charCode)

Source from the content-addressed store, hash-verified

282 }
283
284 function encodeEscape(charCode) {
285 if (charCode < 0x20) {
286 return (charCode < 0x10 ? '\\x0' : '\\x') + charCode.toString(16);
287 }
288 var ch = String.fromCharCode(charCode);
289 return (ch === '\\' || ch === '-' || ch === ']' || ch === '^')
290 ? "\\" + ch : ch;
291 }
292
293 function caseFoldCharset(charSet) {
294 var charsetParts = charSet.substring(1, charSet.length - 1).match(

Callers 2

caseFoldCharsetFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected