diff options
author | Raymond Hettinger <python@rcn.com> | 2015-07-20 07:09:22 (GMT) |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2015-07-20 07:09:22 (GMT) |
commit | 239aba7874d83eee798b19fe3fc11880516fb356 (patch) | |
tree | 66f47dcdb610f9eaf65b0f8e633bcc2c77a154c3 /Modules/_collectionsmodule.c | |
parent | 3018cc49e88721ef50c80b2d832b25dd4f0fe9d7 (diff) | |
download | cpython-239aba7874d83eee798b19fe3fc11880516fb356.zip cpython-239aba7874d83eee798b19fe3fc11880516fb356.tar.gz cpython-239aba7874d83eee798b19fe3fc11880516fb356.tar.bz2 |
Issue #19663: Improve error message for defaultdict.
Diffstat (limited to 'Modules/_collectionsmodule.c')
-rw-r--r-- | Modules/_collectionsmodule.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_collectionsmodule.c b/Modules/_collectionsmodule.c index 627fad5..65803a4 100644 --- a/Modules/_collectionsmodule.c +++ b/Modules/_collectionsmodule.c @@ -1682,7 +1682,7 @@ defdict_init(PyObject *self, PyObject *args, PyObject *kwds) newdefault = PyTuple_GET_ITEM(args, 0); if (!PyCallable_Check(newdefault) && newdefault != Py_None) { PyErr_SetString(PyExc_TypeError, - "first argument must be callable"); + "first argument must be callable or None"); return -1; } } |