[Python-checkins] cpython (merge 3.3 -> default): Issue #17902: Clarify doc of ElementTree.iterparse and IncrementalParser

eli.bendersky python-checkins at python.org
Sun Aug 4 03:55:32 CEST 2013


http://hg.python.org/cpython/rev/96f45011957e
changeset:   85008:96f45011957e
parent:      85006:ce0be0d03c0a
parent:      85007:a5a5ba4f71ad
user:        Eli Bendersky <eliben at gmail.com>
date:        Sat Aug 03 18:55:10 2013 -0700
summary:
  Issue #17902: Clarify doc of ElementTree.iterparse and IncrementalParser

Based on patch by Aaron Oakley

files:
  Doc/library/xml.etree.elementtree.rst |  5 +++--
  1 files changed, 3 insertions(+), 2 deletions(-)


diff --git a/Doc/library/xml.etree.elementtree.rst b/Doc/library/xml.etree.elementtree.rst
--- a/Doc/library/xml.etree.elementtree.rst
+++ b/Doc/library/xml.etree.elementtree.rst
@@ -416,7 +416,8 @@
    and ``"end-ns"`` (the "ns" events are used to get detailed namespace
    information).  If *events* is omitted, only ``"end"`` events are reported.
    *parser* is an optional parser instance.  If not given, the standard
-   :class:`XMLParser` parser is used.  Returns an :term:`iterator` providing
+   :class:`XMLParser` parser is used.  *parser* can only use the default
+   :class:`TreeBuilder` as a target.  Returns an :term:`iterator` providing
    ``(event, elem)`` pairs.
 
    Note that while :func:`iterparse` builds the tree incrementally, it issues
@@ -880,7 +881,7 @@
    events are used to get detailed namespace information).  If *events* is
    omitted, only ``"end"`` events are reported.  *parser* is an optional
    parser instance.  If not given, the standard :class:`XMLParser` parser is
-   used.
+   used.  *parser* can only use the default :class:`TreeBuilder` as a target.
 
    .. method:: data_received(data)
 

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list