[Python-3000-checkins] r51535 - python/branches/p3yk/Python/bltinmodule.c

guido.van.rossum python-3000-checkins at python.org
Thu Aug 24 04:10:21 CEST 2006


Author: guido.van.rossum
Date: Thu Aug 24 04:10:21 2006
New Revision: 51535

Modified:
   python/branches/p3yk/Python/bltinmodule.c
Log:
Make it compile with C89.


Modified: python/branches/p3yk/Python/bltinmodule.c
==============================================================================
--- python/branches/p3yk/Python/bltinmodule.c	(original)
+++ python/branches/p3yk/Python/bltinmodule.c	Thu Aug 24 04:10:21 2006
@@ -1447,6 +1447,7 @@
 		bign = get_len_of_range_longs(ilow, ihigh, istep);
 	else {
 		int step_zero = PyObject_RichCompareBool(istep, zero, Py_EQ);
+		PyObject *neg_istep;
 		if (step_zero < 0)
 			goto Fail;
 		if (step_zero) {
@@ -1454,7 +1455,7 @@
 				"range() step argument must not be zero");
 			goto Fail;
 		}
-		PyObject *neg_istep = PyNumber_Negative(istep);
+		neg_istep = PyNumber_Negative(istep);
 		if (neg_istep == NULL)
 			goto Fail;
 		bign = get_len_of_range_longs(ihigh, ilow, neg_istep);


More information about the Python-3000-checkins mailing list