summaryrefslogtreecommitdiffstats
path: root/Doc/library/collections.abc.rst
diff options
context:
space:
mode:
authorGuido van Rossum <guido@dropbox.com>2016-04-04 17:59:29 (GMT)
committerGuido van Rossum <guido@dropbox.com>2016-04-04 17:59:29 (GMT)
commit16ca06b8cb2426b540fdab75914d7cd0f715b7f0 (patch)
tree1579954986fe3c8637f41d08702b3f8f58b6a60b /Doc/library/collections.abc.rst
parent9ad764601bb94f48e3048635f47a8e61f2a587b0 (diff)
downloadcpython-16ca06b8cb2426b540fdab75914d7cd0f715b7f0.zip
cpython-16ca06b8cb2426b540fdab75914d7cd0f715b7f0.tar.gz
cpython-16ca06b8cb2426b540fdab75914d7cd0f715b7f0.tar.bz2
Add collections.Reversible. Patch by Ivan Levkivskyi. Fixes issue #25987.
Diffstat (limited to 'Doc/library/collections.abc.rst')
-rw-r--r--Doc/library/collections.abc.rst7
1 files changed, 6 insertions, 1 deletions
diff --git a/Doc/library/collections.abc.rst b/Doc/library/collections.abc.rst
index d9b93ad..608641b 100644
--- a/Doc/library/collections.abc.rst
+++ b/Doc/library/collections.abc.rst
@@ -40,12 +40,13 @@ ABC Inherits from Abstract Methods Mixin
:class:`Hashable` ``__hash__``
:class:`Iterable` ``__iter__``
:class:`Iterator` :class:`Iterable` ``__next__`` ``__iter__``
+:class:`Reversible` :class:`Iterable` ``__reversed__``
:class:`Generator` :class:`Iterator` ``send``, ``throw`` ``close``, ``__iter__``, ``__next__``
:class:`Sized` ``__len__``
:class:`Callable` ``__call__``
:class:`Sequence` :class:`Sized`, ``__getitem__``, ``__contains__``, ``__iter__``, ``__reversed__``,
- :class:`Iterable`, ``__len__`` ``index``, and ``count``
+ :class:`Reversible`, ``__len__`` ``index``, and ``count``
:class:`Container`
:class:`MutableSequence` :class:`Sequence` ``__getitem__``, Inherited :class:`Sequence` methods and
@@ -107,6 +108,10 @@ ABC Inherits from Abstract Methods Mixin
:meth:`~iterator.__next__` methods. See also the definition of
:term:`iterator`.
+.. class:: Reversible
+
+ ABC for classes that provide the :meth:`__reversed__` method.
+
.. class:: Generator
ABC for generator classes that implement the protocol defined in