[Python-checkins] Fix the output of built-in iter() function example in Iterators (Section 9.8) of The Python Tutorial (GH-30110)

miss-islington webhook-mailer at python.org
Thu Dec 16 06:01:24 EST 2021


https://github.com/python/cpython/commit/fb5d314da8f74e624f1ba30389f8ec305e2553a4
commit: fb5d314da8f74e624f1ba30389f8ec305e2553a4
branch: 3.10
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: miss-islington <31488909+miss-islington at users.noreply.github.com>
date: 2021-12-16T03:00:58-08:00
summary:

Fix the output of built-in iter() function example in Iterators (Section 9.8) of The Python Tutorial (GH-30110)


Updated the output for it=iter(s) from <iterator object at 0x00A1DB50> to <str_iterator object at 0x10c90e650>
(cherry picked from commit c5d18a5014f649368b5a4bca94e9ec7d2908b481)

Co-authored-by: Vivek Vashist <vivekvashist at gmail.com>

files:
M Doc/tutorial/classes.rst

diff --git a/Doc/tutorial/classes.rst b/Doc/tutorial/classes.rst
index 0d780e3ba8964..f44cb0b4e905a 100644
--- a/Doc/tutorial/classes.rst
+++ b/Doc/tutorial/classes.rst
@@ -797,7 +797,7 @@ using the :func:`next` built-in function; this example shows how it all works::
    >>> s = 'abc'
    >>> it = iter(s)
    >>> it
-   <iterator object at 0x00A1DB50>
+   <str_iterator object at 0x10c90e650>
    >>> next(it)
    'a'
    >>> next(it)



More information about the Python-checkins mailing list