[Python-checkins] r69975 - in python/branches/py3k: Objects/longobject.c

mark.dickinson python-checkins at python.org
Wed Feb 25 21:33:49 CET 2009


Author: mark.dickinson
Date: Wed Feb 25 21:33:49 2009
New Revision: 69975

Log:
Merged revisions 69974 via svnmerge from 
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r69974 | mark.dickinson | 2009-02-25 20:29:50 +0000 (Wed, 25 Feb 2009) | 3 lines
  
  Replace long with twodigits, to avoid depending
  on sizeof(digit) < sizeof(long)
........


Modified:
   python/branches/py3k/   (props changed)
   python/branches/py3k/Objects/longobject.c

Modified: python/branches/py3k/Objects/longobject.c
==============================================================================
--- python/branches/py3k/Objects/longobject.c	(original)
+++ python/branches/py3k/Objects/longobject.c	Wed Feb 25 21:33:49 2009
@@ -1557,7 +1557,7 @@
 		digit powbase = base;  /* powbase == base ** power */
 		int power = 1;
 		for (;;) {
-			unsigned long newpow = powbase * (unsigned long)base;
+			twodigits newpow = powbase * (twodigits)base;
 			if (newpow >> PyLong_SHIFT)  /* doesn't fit in a digit */
 				break;
 			powbase = (digit)newpow;


More information about the Python-checkins mailing list