From 8f5cdaa784f555149adf5e94fd2e989f99d6b1db Mon Sep 17 00:00:00 2001 From: Raymond Hettinger Date: Sat, 13 Dec 2003 11:26:12 +0000 Subject: * Added a new method flag, METH_COEXIST. * Used the flag to optimize set.__contains__(), dict.__contains__(), dict.__getitem__(), and list.__getitem__(). --- Objects/methodobject.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Objects/methodobject.c') diff --git a/Objects/methodobject.c b/Objects/methodobject.c index 3a92fa45ce..5818616dfb 100644 --- a/Objects/methodobject.c +++ b/Objects/methodobject.c @@ -67,7 +67,7 @@ PyCFunction_Call(PyObject *func, PyObject *arg, PyObject *kw) PyObject *self = PyCFunction_GET_SELF(func); int size; - switch (PyCFunction_GET_FLAGS(func) & ~(METH_CLASS | METH_STATIC)) { + switch (PyCFunction_GET_FLAGS(func) & ~(METH_CLASS | METH_STATIC | METH_COEXIST)) { case METH_VARARGS: if (kw == NULL || PyDict_Size(kw) == 0) return (*meth)(self, arg); -- cgit v1.2.1