mirror of
https://github.com/python/cpython.git
synced 2025-11-01 06:01:29 +00:00
Fix a bug in rendering of \\ by repr() -- it rendered as \\\ instead
of \\.
This commit is contained in:
parent
e4874aeab0
commit
ad9744a67a
1 changed files with 1 additions and 0 deletions
|
|
@ -1758,6 +1758,7 @@ PyObject *unicodeescape_string(const Py_UNICODE *s,
|
||||||
(ch == (Py_UNICODE) PyString_AS_STRING(repr)[1] || ch == '\\')) {
|
(ch == (Py_UNICODE) PyString_AS_STRING(repr)[1] || ch == '\\')) {
|
||||||
*p++ = '\\';
|
*p++ = '\\';
|
||||||
*p++ = (char) ch;
|
*p++ = (char) ch;
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef Py_UNICODE_WIDE
|
#ifdef Py_UNICODE_WIDE
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue