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

Function make_quoted_pairs

Lib/email/_header_value_parser.py:100–102  ·  view source on GitHub ↗

Escape dquote and backslash for use within a quoted-string.

(value)

Source from the content-addressed store, hash-verified

98
99
100def make_quoted_pairs(value):
101 """Escape dquote and backslash for use within a quoted-string."""
102 return str(value).replace('\\', '\\\\').replace('"', '\\"')
103
104
105def make_parenthesis_pairs(value):

Callers 2

quote_stringFunction · 0.85
_refold_parse_treeFunction · 0.85

Calls 2

strFunction · 0.85
replaceMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…