aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Dower <steve.dower@python.org>2019-09-10 15:25:12 +0100
committerGitHub <noreply@github.com>2019-09-10 15:25:12 +0100
commita39a4c7439ed09069e619c10d30a6d0ec9332d1a (patch)
treeda9d2b9a591ef5f19abea4fb9c064561bc902b6b /Doc/reference
parentbpo-37913: document that __length_hint__ can return NotImplemented (GH-15383) (diff)
downloadcpython-a39a4c7439ed09069e619c10d30a6d0ec9332d1a.tar.gz
cpython-a39a4c7439ed09069e619c10d30a6d0ec9332d1a.tar.bz2
cpython-a39a4c7439ed09069e619c10d30a6d0ec9332d1a.zip
bpo-37913: Link to NotImplemented from new docs (GH-15860)
Diffstat (limited to 'Doc/reference')
-rw-r--r--Doc/reference/datamodel.rst6
1 files changed, 3 insertions, 3 deletions
diff --git a/Doc/reference/datamodel.rst b/Doc/reference/datamodel.rst
index 6b9325da2f3..c6c6e407503 100644
--- a/Doc/reference/datamodel.rst
+++ b/Doc/reference/datamodel.rst
@@ -2156,9 +2156,9 @@ through the container; for mappings, :meth:`__iter__` should be the same as
Called to implement :func:`operator.length_hint`. Should return an estimated
length for the object (which may be greater or less than the actual length).
The length must be an integer ``>=`` 0. The return value may also be
- *NotImplemented*, which is treated the same as if the ``__length_hint__``
- method didn't exist at all. This method is purely an optimization and is
- never required for correctness.
+ :const:`NotImplemented`, which is treated the same as if the
+ ``__length_hint__`` method didn't exist at all. This method is purely an
+ optimization and is never required for correctness.
.. versionadded:: 3.4