From: Guido van Rossum Date: Mon, 25 Aug 1997 18:36:23 +0000 (+0000) Subject: Rename roundup() to roundupsize(), as there's a macro roundup() in the X-Git-Tag: v1.5a4~318 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a27d11221303d9cc6a2359b6de2cdaba6a2b1e97;p=python Rename roundup() to roundupsize(), as there's a macro roundup() in the sys/types.h header on many systems that may get pulled in (through WANT_SIGFPE_HANDLER which pulls in signal.h). --- diff --git a/Objects/listobject.c b/Objects/listobject.c index 02fdda6392..c9d4a6bb6a 100644 --- a/Objects/listobject.c +++ b/Objects/listobject.c @@ -43,7 +43,7 @@ PERFORMANCE OF THIS SOFTWARE. ((((n)+(PyTryBlock)-1)/(PyTryBlock))*(PyTryBlock)) static int -roundup(n) +roundupsize(n) int n; { if (n < 500) @@ -52,7 +52,7 @@ roundup(n) return ROUNDUP(n, 100); } -#define NRESIZE(var, type, nitems) PyMem_RESIZE(var, type, roundup(nitems)) +#define NRESIZE(var, type, nitems) PyMem_RESIZE(var, type, roundupsize(nitems)) PyObject * PyList_New(size)