[Python-checkins] cpython: Don't use PyUnicode_MAX_CHAR_VALUE() macro in Py_MAX()
victor.stinner
python-checkins at python.org
Thu Oct 13 01:17:30 CEST 2011
http://hg.python.org/cpython/rev/21a8dcd055f5
changeset: 72905:21a8dcd055f5
user: Victor Stinner <victor.stinner at haypocalc.com>
date: Thu Oct 13 01:12:34 2011 +0200
summary:
Don't use PyUnicode_MAX_CHAR_VALUE() macro in Py_MAX()
files:
Objects/unicodeobject.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c
--- a/Objects/unicodeobject.c
+++ b/Objects/unicodeobject.c
@@ -10257,7 +10257,7 @@
PyUnicode_Concat(PyObject *left, PyObject *right)
{
PyObject *u = NULL, *v = NULL, *w;
- Py_UCS4 maxchar;
+ Py_UCS4 maxchar, maxchar2;
/* Coerce the two arguments */
u = PyUnicode_FromObject(left);
@@ -10278,7 +10278,8 @@
}
maxchar = PyUnicode_MAX_CHAR_VALUE(u);
- maxchar = Py_MAX(maxchar, PyUnicode_MAX_CHAR_VALUE(v));
+ maxchar2 = PyUnicode_MAX_CHAR_VALUE(v);
+ maxchar = Py_MAX(maxchar, maxchar2);
/* Concat the two Unicode strings */
w = PyUnicode_New(
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list