MCPcopy Index your code
hub / github.com/python/cpython / escape_nonascii

Function escape_nonascii

Tools/i18n/pygettext.py:212–213  ·  view source on GitHub ↗
(s, encoding)

Source from the content-addressed store, hash-verified

210
211
212def escape_nonascii(s, encoding):
213 return ''.join(escapes[b] for b in s.encode(encoding))
214
215
216def normalize(s, encoding):

Callers 1

escape_asciiFunction · 0.85

Calls 2

joinMethod · 0.45
encodeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…