diff options
author | Guido van Rossum <guido@python.org> | 2002-08-23 14:11:35 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2002-08-23 14:11:35 (GMT) |
commit | 86c659a32937b7fe991e4f407a2a5f0026bb276d (patch) | |
tree | 941bcd96df6ef372b2178a6426b0d89fc1a10b5f /Python | |
parent | b2628b0f37619cd266e35ad69b729f340c5eaaf6 (diff) | |
download | cpython-86c659a32937b7fe991e4f407a2a5f0026bb276d.zip cpython-86c659a32937b7fe991e4f407a2a5f0026bb276d.tar.gz cpython-86c659a32937b7fe991e4f407a2a5f0026bb276d.tar.bz2 |
The error messages in err_args() -- which is only called when the
required number of args is 0 or 1 -- were reversed. Also change "1"
into "exactly one", the same words as used elsewhere for this
condition.
Diffstat (limited to 'Python')
-rw-r--r-- | Python/ceval.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Python/ceval.c b/Python/ceval.c index 3b984c8..d4be04e 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -3176,12 +3176,12 @@ err_args(PyObject *func, int flags, int nargs) { if (flags & METH_NOARGS) PyErr_Format(PyExc_TypeError, - "%.200s() takes 1 argument (%d given)", + "%.200s() takes no arguments (%d given)", ((PyCFunctionObject *)func)->m_ml->ml_name, nargs); else PyErr_Format(PyExc_TypeError, - "%.200s() takes no arguments (%d given)", + "%.200s() takes exactly one argument (%d given)", ((PyCFunctionObject *)func)->m_ml->ml_name, nargs); } |