diff options
author | Antoine Pitrou <solipsis@pitrou.net> | 2013-04-11 21:02:20 +0200 |
---|---|---|
committer | Antoine Pitrou <solipsis@pitrou.net> | 2013-04-11 21:02:20 +0200 |
commit | de8c250d2429f3e0b97ceb9b8c8b39a286106903 (patch) | |
tree | 6e5fdde10d595e643f1c2d2f75d08b2a601879d9 /Objects/methodobject.c | |
parent | 3a5b24bc5221c7677d257ae3829374ceb7a4dcf3 (diff) | |
parent | 49f7023c78293a39833c15b6b043b0734c13b6dd (diff) | |
download | cpython-de8c250d2429f3e0b97ceb9b8c8b39a286106903.tar.gz |
Fix supernumerary 's' in sys._debugmallocstats() output.
Diffstat (limited to 'Objects/methodobject.c')
-rw-r--r-- | Objects/methodobject.c | 23 |
1 files changed, 9 insertions, 14 deletions
diff --git a/Objects/methodobject.c b/Objects/methodobject.c index f0685dd606..9944fade10 100644 --- a/Objects/methodobject.c +++ b/Objects/methodobject.c @@ -13,6 +13,15 @@ static int numfree = 0; #define PyCFunction_MAXFREELIST 256 #endif +/* undefine macro trampoline to PyCFunction_NewEx */ +#undef PyCFunction_New + +PyObject * +PyCFunction_New(PyMethodDef *ml, PyObject *self) +{ + return PyCFunction_NewEx(ml, self, NULL); +} + PyObject * PyCFunction_NewEx(PyMethodDef *ml, PyObject *self, PyObject *module) { @@ -346,17 +355,3 @@ _PyCFunction_DebugMallocStats(FILE *out) "free PyCFunctionObject", numfree, sizeof(PyCFunctionObject)); } - -/* PyCFunction_New() is now just a macro that calls PyCFunction_NewEx(), - but it's part of the API so we need to keep a function around that - existing C extensions can call. -*/ - -#undef PyCFunction_New -PyAPI_FUNC(PyObject *) PyCFunction_New(PyMethodDef *, PyObject *); - -PyObject * -PyCFunction_New(PyMethodDef *ml, PyObject *self) -{ - return PyCFunction_NewEx(ml, self, NULL); -} |