From: Guido van Rossum Date: Tue, 20 May 1997 22:09:08 +0000 (+0000) Subject: Renamed a local variable from 'PyCFunction' (which is also a typedef X-Git-Tag: v1.5a3~513 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=a9040ec5d9dc92bc8beb41de2a7f1f5cbb2b917a;p=thirdparty%2FPython%2Fcpython.git Renamed a local variable from 'PyCFunction' (which is also a typedef in methodobject.h) to 'func'. /bin/cc on SunOS 4.x didn't grok this. --- diff --git a/Objects/abstract.c b/Objects/abstract.c index b6d4dda6d4c5..82eec95a828a 100644 --- a/Objects/abstract.c +++ b/Objects/abstract.c @@ -1034,7 +1034,7 @@ PyObject_CallMethod(va_alist) va_dcl #endif { va_list va; - PyObject *args, *PyCFunction=0, *retval; + PyObject *args, *func=0, *retval; #ifdef HAVE_STDARG_PROTOTYPES va_start(va, format); #else @@ -1053,15 +1053,15 @@ PyObject_CallMethod(va_alist) va_dcl return Py_ReturnNullError(); } - PyCFunction=PyObject_GetAttrString(o,name); - if(! PyCFunction) + func=PyObject_GetAttrString(o,name); + if(! func) { va_end(va); PyErr_SetString(PyExc_AttributeError,name); return 0; } - if(! (PyCallable_Check(PyCFunction))) + if(! (PyCallable_Check(func))) { va_end(va); PyErr_SetString(PyExc_TypeError,"call of non-callable attribute"); @@ -1086,9 +1086,9 @@ PyObject_CallMethod(va_alist) va_dcl args=a; } - retval = PyObject_CallObject(PyCFunction,args); + retval = PyObject_CallObject(func,args); Py_DECREF(args); - Py_DECREF(PyCFunction); + Py_DECREF(func); return retval; }