mirror of
https://github.com/python/cpython.git
synced 2025-11-17 17:46:45 +00:00
Fixed bug #1459029 - unicode reprs were double-escaped.
Backed out an old patch from 2000.
This commit is contained in:
parent
80a5d01790
commit
262c00a21e
2 changed files with 3 additions and 1 deletions
|
|
@ -12,6 +12,8 @@ What's New in Python 2.5 alpha 1?
|
||||||
Core and builtins
|
Core and builtins
|
||||||
-----------------
|
-----------------
|
||||||
|
|
||||||
|
- Fixed bug #1459029 - unicode reprs were double-escaped.
|
||||||
|
|
||||||
- Patch #1396919: The system scope threads are reenabled on FreeBSD
|
- Patch #1396919: The system scope threads are reenabled on FreeBSD
|
||||||
5.4 and later versions.
|
5.4 and later versions.
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -316,7 +316,7 @@ PyObject_Repr(PyObject *v)
|
||||||
#ifdef Py_USING_UNICODE
|
#ifdef Py_USING_UNICODE
|
||||||
if (PyUnicode_Check(res)) {
|
if (PyUnicode_Check(res)) {
|
||||||
PyObject* str;
|
PyObject* str;
|
||||||
str = PyUnicode_AsUnicodeEscapeString(res);
|
str = PyUnicode_AsEncodedString(res, NULL, NULL);
|
||||||
Py_DECREF(res);
|
Py_DECREF(res);
|
||||||
if (str)
|
if (str)
|
||||||
res = str;
|
res = str;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue