From: Petri Lehtinen Date: Sun, 30 Oct 2011 11:56:41 +0000 (+0200) Subject: Avoid unnecessary recursive function calls (closes #10519) X-Git-Tag: v3.3.0a1~993^2~18 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=5acc27ebe442306c667ddd2422afee2c38d2e1aa;p=python Avoid unnecessary recursive function calls (closes #10519) --- diff --git a/Objects/setobject.c b/Objects/setobject.c index 48edad8a31..9f39fcbadb 100644 --- a/Objects/setobject.c +++ b/Objects/setobject.c @@ -1877,7 +1877,7 @@ set_contains(PySetObject *so, PyObject *key) tmpkey = make_new_set(&PyFrozenSet_Type, key); if (tmpkey == NULL) return -1; - rv = set_contains(so, tmpkey); + rv = set_contains_key(so, tmpkey); Py_DECREF(tmpkey); } return rv; @@ -1942,7 +1942,7 @@ set_discard(PySetObject *so, PyObject *key) tmpkey = make_new_set(&PyFrozenSet_Type, key); if (tmpkey == NULL) return NULL; - result = set_discard(so, tmpkey); + result = set_discard_key(so, tmpkey); Py_DECREF(tmpkey); return result; }