summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Misc/NEWS3
-rw-r--r--Modules/_elementtree.c2
2 files changed, 4 insertions, 1 deletions
diff --git a/Misc/NEWS b/Misc/NEWS
index e71a20df2b..aecd0c325f 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -44,6 +44,9 @@ Core and Builtins
Library
-------
+- Issue #28314: Fix function declaration (C flags) for the getiterator() method
+ of xml.etree.ElementTree.Element.
+
- Issue #28148: Stop using localtime() and gmtime() in the time
module.
diff --git a/Modules/_elementtree.c b/Modules/_elementtree.c
index dd8417a1ac..3362195ed6 100644
--- a/Modules/_elementtree.c
+++ b/Modules/_elementtree.c
@@ -3702,7 +3702,7 @@ static PyMethodDef element_methods[] = {
_ELEMENTTREE_ELEMENT_ITERTEXT_METHODDEF
_ELEMENTTREE_ELEMENT_ITERFIND_METHODDEF
- {"getiterator", (PyCFunction)_elementtree_Element_iter, METH_VARARGS|METH_KEYWORDS, _elementtree_Element_iter__doc__},
+ {"getiterator", (PyCFunction)_elementtree_Element_iter, METH_FASTCALL, _elementtree_Element_iter__doc__},
_ELEMENTTREE_ELEMENT_GETCHILDREN_METHODDEF
_ELEMENTTREE_ELEMENT_ITEMS_METHODDEF