diff options
Diffstat (limited to 'Objects/setobject.c')
-rw-r--r-- | Objects/setobject.c | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/Objects/setobject.c b/Objects/setobject.c index 47db6b245ca..80101dda9be 100644 --- a/Objects/setobject.c +++ b/Objects/setobject.c @@ -703,7 +703,7 @@ set_merge(PySetObject *so, PyObject *otherset) } static PyObject * -set_pop(PySetObject *so) +set_pop(PySetObject *so, PyObject *Py_UNUSED(ignored)) { /* Make sure the search finger is in bounds */ Py_ssize_t i = so->finger & so->mask; @@ -833,7 +833,7 @@ setiter_traverse(setiterobject *si, visitproc visit, void *arg) } static PyObject * -setiter_len(setiterobject *si) +setiter_len(setiterobject *si, PyObject *Py_UNUSED(ignored)) { Py_ssize_t len = 0; if (si->si_set != NULL && si->si_used == si->si_set->used) @@ -846,7 +846,7 @@ PyDoc_STRVAR(length_hint_doc, "Private method returning an estimate of len(list( static PyObject *setiter_iternext(setiterobject *si); static PyObject * -setiter_reduce(setiterobject *si) +setiter_reduce(setiterobject *si, PyObject *Py_UNUSED(ignored)) { PyObject *list; setiterobject tmp; @@ -1175,25 +1175,25 @@ set_swap_bodies(PySetObject *a, PySetObject *b) } static PyObject * -set_copy(PySetObject *so) +set_copy(PySetObject *so, PyObject *Py_UNUSED(ignored)) { return make_new_set_basetype(Py_TYPE(so), (PyObject *)so); } static PyObject * -frozenset_copy(PySetObject *so) +frozenset_copy(PySetObject *so, PyObject *Py_UNUSED(ignored)) { if (PyFrozenSet_CheckExact(so)) { Py_INCREF(so); return (PyObject *)so; } - return set_copy(so); + return set_copy(so, NULL); } PyDoc_STRVAR(copy_doc, "Return a shallow copy of a set."); static PyObject * -set_clear(PySetObject *so) +set_clear(PySetObject *so, PyObject *Py_UNUSED(ignored)) { set_clear_internal(so); Py_RETURN_NONE; @@ -1208,7 +1208,7 @@ set_union(PySetObject *so, PyObject *args) PyObject *other; Py_ssize_t i; - result = (PySetObject *)set_copy(so); + result = (PySetObject *)set_copy(so, NULL); if (result == NULL) return NULL; @@ -1237,7 +1237,7 @@ set_or(PySetObject *so, PyObject *other) if (!PyAnySet_Check(so) || !PyAnySet_Check(other)) Py_RETURN_NOTIMPLEMENTED; - result = (PySetObject *)set_copy(so); + result = (PySetObject *)set_copy(so, NULL); if (result == NULL) return NULL; if ((PyObject *)so == other) @@ -1270,7 +1270,7 @@ set_intersection(PySetObject *so, PyObject *other) int rv; if ((PyObject *)so == other) - return set_copy(so); + return set_copy(so, NULL); result = (PySetObject *)make_new_set_basetype(Py_TYPE(so), NULL); if (result == NULL) @@ -1343,7 +1343,7 @@ set_intersection_multi(PySetObject *so, PyObject *args) PyObject *result = (PyObject *)so; if (PyTuple_GET_SIZE(args) == 0) - return set_copy(so); + return set_copy(so, NULL); Py_INCREF(so); for (i=0 ; i<PyTuple_GET_SIZE(args) ; i++) { @@ -1542,7 +1542,7 @@ set_copy_and_difference(PySetObject *so, PyObject *other) { PyObject *result; - result = set_copy(so); + result = set_copy(so, NULL); if (result == NULL) return NULL; if (set_difference_update_internal((PySetObject *) result, other) == 0) @@ -1562,7 +1562,7 @@ set_difference(PySetObject *so, PyObject *other) int rv; if (PySet_GET_SIZE(so) == 0) { - return set_copy(so); + return set_copy(so, NULL); } if (PyAnySet_Check(other)) { @@ -1630,7 +1630,7 @@ set_difference_multi(PySetObject *so, PyObject *args) PyObject *result, *other; if (PyTuple_GET_SIZE(args) == 0) - return set_copy(so); + return set_copy(so, NULL); other = PyTuple_GET_ITEM(args, 0); result = set_difference(so, other); @@ -1681,7 +1681,7 @@ set_symmetric_difference_update(PySetObject *so, PyObject *other) int rv; if ((PyObject *)so == other) - return set_clear(so); + return set_clear(so, NULL); if (PyDict_CheckExact(other)) { PyObject *value; @@ -1976,7 +1976,7 @@ PyDoc_STRVAR(discard_doc, If the element is not a member, do nothing."); static PyObject * -set_reduce(PySetObject *so) +set_reduce(PySetObject *so, PyObject *Py_UNUSED(ignored)) { PyObject *keys=NULL, *args=NULL, *result=NULL, *dict=NULL; _Py_IDENTIFIER(__dict__); @@ -2002,7 +2002,7 @@ done: } static PyObject * -set_sizeof(PySetObject *so) +set_sizeof(PySetObject *so, PyObject *Py_UNUSED(ignored)) { Py_ssize_t res; @@ -2044,7 +2044,7 @@ static PySequenceMethods set_as_sequence = { /* set object ********************************************************/ #ifdef Py_DEBUG -static PyObject *test_c_api(PySetObject *so); +static PyObject *test_c_api(PySetObject *so, PyObject *Py_UNUSED(ignored)); PyDoc_STRVAR(test_c_api_doc, "Exercises C API. Returns True.\n\ All is well if assertions don't fail."); @@ -2379,7 +2379,7 @@ PySet_Pop(PyObject *set) PyErr_BadInternalCall(); return NULL; } - return set_pop((PySetObject *)set); + return set_pop((PySetObject *)set, NULL); } int @@ -2408,7 +2408,7 @@ PyObject *_PySet_Dummy = dummy; } while(0) static PyObject * -test_c_api(PySetObject *so) +test_c_api(PySetObject *so, PyObject *Py_UNUSED(ignored)) { Py_ssize_t count; const char *s; |