From 5f937ed88b82511df0375d54359b03a6b509a67a Mon Sep 17 00:00:00 2001 From: Graham Dumpleton Date: Mon, 19 Aug 2013 22:20:27 +1000 Subject: [PATCH] Wrong cast to satisfy type checking of method dispatch table when compiling. --- src/_wrappers.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/_wrappers.c b/src/_wrappers.c index f4a9fae..7e49e06 100644 --- a/src/_wrappers.c +++ b/src/_wrappers.c @@ -461,9 +461,9 @@ static PyObject *WraptObjectProxy_iter(WraptObjectProxyObject *self) static PyMethodDef WraptObjectProxy_methods[] = { { "__dir__", (PyCFunction)WraptObjectProxy_dir, METH_NOARGS, 0 }, - { "__enter__", (PyCFunctionWithKeywords)WraptObjectProxy_enter, + { "__enter__", (PyCFunction)WraptObjectProxy_enter, METH_VARARGS | METH_KEYWORDS, 0 }, - { "__exit__", (PyCFunctionWithKeywords)WraptObjectProxy_exit, + { "__exit__", (PyCFunction)WraptObjectProxy_exit, METH_VARARGS | METH_KEYWORDS, 0 }, { NULL, NULL }, };