PyDoc_STRVAR(remove_doc,
"D.remove(value) -- remove first occurrence of value.");
-static void
+static int
deque_clear(dequeobject *deque)
{
block *b;
PyObject *item;
if (deque->len == 0)
- return;
+ return 0;
/* During the process of clearing a deque, decrefs can cause the
deque to mutate. To avoid fatal confusion, we have to make the
}
assert(leftblock->rightlink == NULL);
freeblock(leftblock);
- return;
+ return 0;
alternate_method:
while (deque->len) {
assert (item != NULL);
Py_DECREF(item);
}
+ return 0;
}
static PyObject *