[Python-checkins] r76333 - python/trunk/Objects/intobject.c

mark.dickinson python-checkins at python.org
Mon Nov 16 20:17:16 CET 2009


Author: mark.dickinson
Date: Mon Nov 16 20:17:16 2009
New Revision: 76333

Log:
Silence another MSVC warning about unary minus.

Modified:
   python/trunk/Objects/intobject.c

Modified: python/trunk/Objects/intobject.c
==============================================================================
--- python/trunk/Objects/intobject.c	(original)
+++ python/trunk/Objects/intobject.c	Mon Nov 16 20:17:16 2009
@@ -1117,7 +1117,7 @@
 	long n = v->ob_ival;
 	unsigned long absn;
 	p = bufend = buf + sizeof(buf);
-	absn = n < 0 ? -(unsigned long)n : n;
+	absn = n < 0 ? 0UL - n : n;
 	do {
 		*--p = '0' + absn % 10;
 		absn /= 10;


More information about the Python-checkins mailing list