summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorFred Drake <fdrake@acm.org>2002-05-01 20:36:39 (GMT)
committerFred Drake <fdrake@acm.org>2002-05-01 20:36:39 (GMT)
commit0ebacc8b3892009fb628412577cb1ec1113b33de (patch)
tree7199342e7dbe230a2476ff2d22d2d7767aefffa4 /Modules
parent7f781c9aabe35cc674afb7dbaeef191be6b25cbb (diff)
downloadcpython-0ebacc8b3892009fb628412577cb1ec1113b33de.zip
cpython-0ebacc8b3892009fb628412577cb1ec1113b33de.tar.gz
cpython-0ebacc8b3892009fb628412577cb1ec1113b33de.tar.bz2
Pickler_clear_memo(): convert to METH_NOARGS.
Diffstat (limited to 'Modules')
-rw-r--r--Modules/cPickle.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/Modules/cPickle.c b/Modules/cPickle.c
index a6c5e9d..8ba423e 100644
--- a/Modules/cPickle.c
+++ b/Modules/cPickle.c
@@ -2120,8 +2120,6 @@ dump(Picklerobject *self, PyObject *args)
static PyObject *
Pickle_clear_memo(Picklerobject *self, PyObject *args)
{
- if (!PyArg_ParseTuple(args,":clear_memo"))
- return NULL;
if (self->memo)
PyDict_Clear(self->memo);
Py_INCREF(Py_None);
@@ -2290,9 +2288,8 @@ static struct PyMethodDef Pickler_methods[] =
{
{"dump", (PyCFunction)Pickler_dump, METH_VARARGS,
"dump(object) --"
- "Write an object in pickle format to the object's pickle stream\n"
- },
- {"clear_memo", (PyCFunction)Pickle_clear_memo, METH_VARARGS,
+ "Write an object in pickle format to the object's pickle stream"},
+ {"clear_memo", (PyCFunction)Pickle_clear_memo, METH_NOARGS,
"clear_memo() -- Clear the picklers memo"},
{"getvalue", (PyCFunction)Pickle_getvalue, METH_VARARGS,
"getvalue() -- Finish picking a list-based pickle"},