summaryrefslogtreecommitdiffstats
path: root/Modules/clinic/_dbmmodule.c.h
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/clinic/_dbmmodule.c.h')
-rw-r--r--Modules/clinic/_dbmmodule.c.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/clinic/_dbmmodule.c.h b/Modules/clinic/_dbmmodule.c.h
index 8157716..d956810 100644
--- a/Modules/clinic/_dbmmodule.c.h
+++ b/Modules/clinic/_dbmmodule.c.h
@@ -35,7 +35,7 @@ _dbm_dbm_keys_impl(dbmobject *self, PyTypeObject *cls);
static PyObject *
_dbm_dbm_keys(dbmobject *self, PyTypeObject *cls, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
{
- if (nargs) {
+ if (nargs || (kwnames && PyTuple_GET_SIZE(kwnames))) {
PyErr_SetString(PyExc_TypeError, "keys() takes no arguments");
return NULL;
}
@@ -172,4 +172,4 @@ skip_optional:
exit:
return return_value;
}
-/*[clinic end generated code: output=5798278a05032d0e input=a9049054013a1b77]*/
+/*[clinic end generated code: output=57447621196fddb6 input=a9049054013a1b77]*/