]> granicus.if.org Git - python/commitdiff
bpo-34748: link to :ref:`partial-objects` in functools.partial doc. (GH-9809)
authorAndrei Petre <p31andrei@gmail.com>
Tue, 23 Oct 2018 06:11:20 +0000 (23:11 -0700)
committerXiang Zhang <angwerzx@126.com>
Tue, 23 Oct 2018 06:11:20 +0000 (14:11 +0800)
Doc/library/functools.rst

index ec3d5a529e658e47d7f34f173abbab4be8605dcb..40abdc24883c978c9dfc928e0bd368961f3514cd 100644 (file)
@@ -205,10 +205,11 @@ The :mod:`functools` module defines the following functions:
 
 .. function:: partial(func, *args, **keywords)
 
-   Return a new :class:`partial` object which when called will behave like *func*
-   called with the positional arguments *args* and keyword arguments *keywords*. If
-   more arguments are supplied to the call, they are appended to *args*. If
-   additional keyword arguments are supplied, they extend and override *keywords*.
+   Return a new :ref:`partial object<partial-objects>` which when called
+   will behave like *func* called with the positional arguments *args*
+   and keyword arguments *keywords*. If more arguments are supplied to the
+   call, they are appended to *args*. If additional keyword arguments are
+   supplied, they extend and override *keywords*.
    Roughly equivalent to::
 
       def partial(func, *args, **keywords):
@@ -246,7 +247,7 @@ The :mod:`functools` module defines the following functions:
    :func:`classmethod`, :func:`staticmethod`, :func:`abstractmethod` or
    another instance of :class:`partialmethod`), calls to ``__get__`` are
    delegated to the underlying descriptor, and an appropriate
-   :class:`partial` object returned as the result.
+   :ref:`partial object<partial-objects>` returned as the result.
 
    When *func* is a non-descriptor callable, an appropriate bound method is
    created dynamically. This behaves like a normal Python function when