diff options
author | Thomas Wouters <thomas@python.org> | 2006-03-01 05:41:20 (GMT) |
---|---|---|
committer | Thomas Wouters <thomas@python.org> | 2006-03-01 05:41:20 (GMT) |
commit | 8b87a0b5fcc3db361d720c365273114eef5d9467 (patch) | |
tree | f8eb419c2aa688376ebda4a128a3eed3d4f35f29 /Objects/intobject.c | |
parent | 572a9f32dc1a04ff72d2bcf6389f1db736e0ad8c (diff) | |
download | cpython-8b87a0b5fcc3db361d720c365273114eef5d9467.zip cpython-8b87a0b5fcc3db361d720c365273114eef5d9467.tar.gz cpython-8b87a0b5fcc3db361d720c365273114eef5d9467.tar.bz2 |
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.
Diffstat (limited to 'Objects/intobject.c')
-rw-r--r-- | Objects/intobject.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/Objects/intobject.c b/Objects/intobject.c index b0876ae..d7a64be 100644 --- a/Objects/intobject.c +++ b/Objects/intobject.c @@ -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; } |