summaryrefslogtreecommitdiffstats
path: root/Modules/clinic/_elementtree.c.h
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/clinic/_elementtree.c.h')
-rw-r--r--Modules/clinic/_elementtree.c.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/Modules/clinic/_elementtree.c.h b/Modules/clinic/_elementtree.c.h
index 02375c8..9622591 100644
--- a/Modules/clinic/_elementtree.c.h
+++ b/Modules/clinic/_elementtree.c.h
@@ -87,7 +87,7 @@ _elementtree_Element___copy___impl(ElementObject *self, PyTypeObject *cls);
static PyObject *
_elementtree_Element___copy__(ElementObject *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, "__copy__() takes no arguments");
return NULL;
}
@@ -644,7 +644,7 @@ _elementtree_Element_itertext_impl(ElementObject *self, PyTypeObject *cls);
static PyObject *
_elementtree_Element_itertext(ElementObject *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, "itertext() takes no arguments");
return NULL;
}
@@ -1219,4 +1219,4 @@ skip_optional:
exit:
return return_value;
}
-/*[clinic end generated code: output=8fdaa17d3262800a input=a9049054013a1b77]*/
+/*[clinic end generated code: output=218ec9e6a889f796 input=a9049054013a1b77]*/