diff Objects/stringobject.c @ 25233:8d751b62ecc4 legacy-trunk

Fix warnings on 64-bit platforms about casts from pointers to ints. Two of these were real bugs.
author Guido van Rossum <guido@python.org>
date Thu, 12 Sep 2002 14:43:41 +0000
parents f4e9f09df4f2
children 5c6fac95a94b
line wrap: on
line diff
--- a/Objects/stringobject.c	Thu Sep 12 14:41:20 2002 +0000
+++ b/Objects/stringobject.c	Thu Sep 12 14:43:41 2002 +0000
@@ -3883,7 +3883,8 @@
 				PyErr_Format(PyExc_ValueError,
 				  "unsupported format character '%c' (0x%x) "
 				  "at index %i",
-				  c, c, fmt - 1 - PyString_AsString(format));
+				  c, c,
+				  (int)(fmt - 1 - PyString_AsString(format)));
 				goto error;
 			}
 			if (sign) {