summaryrefslogtreecommitdiffstats
path: root/Doc/library
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2014-09-05 20:34:12 (GMT)
committerSerhiy Storchaka <storchaka@gmail.com>2014-09-05 20:34:12 (GMT)
commitea217728c3b00ddc4ceedd4a4c5c37a496a16b45 (patch)
treeb79f9a7538be910e4881b2e729b27b1ccc8bb98d /Doc/library
parent749022da3643d1693876b33bd6bb410a0c1e9c51 (diff)
downloadcpython-ea217728c3b00ddc4ceedd4a4c5c37a496a16b45.zip
cpython-ea217728c3b00ddc4ceedd4a4c5c37a496a16b45.tar.gz
cpython-ea217728c3b00ddc4ceedd4a4c5c37a496a16b45.tar.bz2
Issue #20643: Fixed references to the next() method (distinguish from the
next() function).
Diffstat (limited to 'Doc/library')
-rw-r--r--Doc/library/2to3.rst2
-rw-r--r--Doc/library/collections.rst4
-rw-r--r--Doc/library/stdtypes.rst8
3 files changed, 7 insertions, 7 deletions
diff --git a/Doc/library/2to3.rst b/Doc/library/2to3.rst
index a927510..7355426 100644
--- a/Doc/library/2to3.rst
+++ b/Doc/library/2to3.rst
@@ -289,7 +289,7 @@ and off individually. They are described here in more detail.
.. 2to3fixer:: next
Converts the use of iterator's :meth:`~iterator.next` methods to the
- :func:`next` function. It also renames :meth:`next` methods to
+ :func:`next` function. It also renames :meth:`~iterator.next` methods to
:meth:`~iterator.__next__`.
.. 2to3fixer:: nonzero
diff --git a/Doc/library/collections.rst b/Doc/library/collections.rst
index f00b870..b947e27 100644
--- a/Doc/library/collections.rst
+++ b/Doc/library/collections.rst
@@ -954,8 +954,8 @@ ABC Inherits from Abstract Methods Mixin
.. class:: Iterator
- ABC for classes that provide the :meth:`__iter__` and :meth:`next` methods.
- See also the definition of :term:`iterator`.
+ ABC for classes that provide the :meth:`~iterator.__iter__` and
+ :meth:`~iterator.next` methods. See also the definition of :term:`iterator`.
.. class:: Sequence
MutableSequence
diff --git a/Doc/library/stdtypes.rst b/Doc/library/stdtypes.rst
index f229967..56f0957 100644
--- a/Doc/library/stdtypes.rst
+++ b/Doc/library/stdtypes.rst
@@ -652,7 +652,7 @@ specific sequence types, dictionaries, and other more specialized forms. The
specific types are not important beyond their implementation of the iterator
protocol.
-The intention of the protocol is that once an iterator's :meth:`next` method
+The intention of the protocol is that once an iterator's :meth:`~iterator.next` method
raises :exc:`StopIteration`, it will continue to do so on subsequent calls.
Implementations that do not obey this property are deemed broken. (This
constraint was added in Python 2.3; in Python 2.2, various iterators are broken
@@ -667,9 +667,9 @@ Generator Types
Python's :term:`generator`\s provide a convenient way to implement the iterator
protocol. If a container object's :meth:`__iter__` method is implemented as a
generator, it will automatically return an iterator object (technically, a
-generator object) supplying the :meth:`__iter__` and :meth:`next` methods. More
-information about generators can be found in :ref:`the documentation for the
-yield expression <yieldexpr>`.
+generator object) supplying the :meth:`~iterator.__iter__` and
+:meth:`~iterator.next` methods. More information about generators can be found
+in :ref:`the documentation for the yield expression <yieldexpr>`.
.. _typesseq: