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:
Thomas Wouters 2006-03-01 05:41:20 +00:00
parent 572a9f32dc
commit 8b87a0b5fc
3 changed files with 31 additions and 12 deletions

View file

@ -1326,9 +1326,13 @@ PyFloat_Fini(void)
p->ob_refcnt != 0) {
char buf[100];
PyFloat_AsString(buf, p);
/* XXX(twouters) cast refcount to
long until %zd is universally
available
*/
fprintf(stderr,
"# <float at %p, refcnt=%d, val=%s>\n",
p, p->ob_refcnt, buf);
"# <float at %p, refcnt=%ld, val=%s>\n",
p, (long)p->ob_refcnt, buf);
}
}
list = list->next;