From e12dc28c3815b241b071b5ae4e7de7b9a5ee53a2 Mon Sep 17 00:00:00 2001 From: Ezio Melotti Date: Sun, 7 Oct 2012 12:09:36 +0300 Subject: Fix markup. --- Doc/library/operator.rst | 4 ++-- Doc/reference/datamodel.rst | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Doc/library/operator.rst b/Doc/library/operator.rst index 1cd87fc..877a790 100644 --- a/Doc/library/operator.rst +++ b/Doc/library/operator.rst @@ -238,8 +238,8 @@ their character equivalents. .. function:: length_hint(obj, default=0) Return an estimated length for the object *o*. First trying to return its - actual length, then an estimate using ``__length_hint__``, and finally - returning the default value. + actual length, then an estimate using :meth:`object.__length_hint__`, and + finally returning the default value. .. versionadded:: 3.4 diff --git a/Doc/reference/datamodel.rst b/Doc/reference/datamodel.rst index 111ad8b..66dc180 100644 --- a/Doc/reference/datamodel.rst +++ b/Doc/reference/datamodel.rst @@ -1807,7 +1807,7 @@ through the container; for mappings, :meth:`__iter__` should be the same as .. method:: object.__length_hint__(self) - Called to implement ``operator.length_hint``. Should return an estimated + 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. This method is purely an optimization and is never required for correctness. -- cgit v0.12