mirror of
https://github.com/python/cpython.git
synced 2025-08-27 12:16:04 +00:00
Fox for SF bug #123859: %[duxXo] long formats inconsistent.
This commit is contained in:
parent
469d5bb0b4
commit
a3a3a030af
4 changed files with 50 additions and 24 deletions
|
@ -5020,9 +5020,7 @@ PyObject *PyUnicode_Format(PyObject *format,
|
|||
case 'X':
|
||||
if (c == 'i')
|
||||
c = 'd';
|
||||
if (PyLong_Check(v) && PyLong_AsLong(v) == -1
|
||||
&& PyErr_Occurred()) {
|
||||
PyErr_Clear();
|
||||
if (PyLong_Check(v)) {
|
||||
temp = formatlong(v, flags, prec, c);
|
||||
if (!temp)
|
||||
goto onError;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue