mirror of
https://github.com/python/cpython.git
synced 2025-07-24 11:44:31 +00:00
Use %ld and casts to long for refcount printing, in absense of a universally
available %zd format character. Mark with an XXX comment so we can fix this, later.
This commit is contained in:
parent
572a9f32dc
commit
8b87a0b5fc
3 changed files with 31 additions and 12 deletions
|
@ -1220,9 +1220,14 @@ PyInt_Fini(void)
|
|||
i < N_INTOBJECTS;
|
||||
i++, p++) {
|
||||
if (PyInt_CheckExact(p) && p->ob_refcnt != 0)
|
||||
/* XXX(twouters) cast refcount to
|
||||
long until %zd is universally
|
||||
available
|
||||
*/
|
||||
fprintf(stderr,
|
||||
"# <int at %p, refcnt=%d, val=%ld>\n",
|
||||
p, p->ob_refcnt, p->ob_ival);
|
||||
"# <int at %p, refcnt=%ld, val=%ld>\n",
|
||||
p, (long)p->ob_refcnt,
|
||||
p->ob_ival);
|
||||
}
|
||||
list = list->next;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue