[Python-checkins] bpo-28235: Fix xml.etree.ElementTree.fromstring docs (GH-11903)

Cheryl Sabella webhook-mailer at python.org
Thu Feb 21 19:34:07 EST 2019

commit: e5458bdb6af81f9b98acecd8819c60016d3f1441
branch: master
author: Manjusaka <lizheao940510 at gmail.com>
committer: Cheryl Sabella <cheryl.sabella at gmail.com>
date: 2019-02-21T19:33:57-05:00

bpo-28235: Fix xml.etree.ElementTree.fromstring docs (GH-11903)

M Doc/library/xml.etree.elementtree.rst

diff --git a/Doc/library/xml.etree.elementtree.rst b/Doc/library/xml.etree.elementtree.rst
index aae80140374c..4a7cf6f09588 100644
--- a/Doc/library/xml.etree.elementtree.rst
+++ b/Doc/library/xml.etree.elementtree.rst
@@ -494,10 +494,12 @@ Functions
       by the user.
-.. function:: fromstring(text)
+.. function:: fromstring(text, parser=None)
    Parses an XML section from a string constant.  Same as :func:`XML`.  *text*
-   is a string containing XML data.  Returns an :class:`Element` instance.
+   is a string containing XML data.  *parser* is an optional parser instance.
+   If not given, the standard :class:`XMLParser` parser is used.
+   Returns an :class:`Element` instance.
 .. function:: fromstringlist(sequence, parser=None)

More information about the Python-checkins mailing list