@@ -200,11 +200,11 @@ The :mod:`functools` module defines the following functions:
200200 has no effect.
201201
202202 To help measure the effectiveness of the cache and tune the *maxsize *
203- parameter, the wrapped function is instrumented with a :func: `cache_info `
203+ parameter, the wrapped function is instrumented with a :func: `! cache_info `
204204 function that returns a :term: `named tuple ` showing *hits *, *misses *,
205205 *maxsize * and *currsize *.
206206
207- The decorator also provides a :func: `cache_clear ` function for clearing or
207+ The decorator also provides a :func: `! cache_clear ` function for clearing or
208208 invalidating the cache.
209209
210210 The original underlying function is accessible through the
@@ -284,9 +284,9 @@ The :mod:`functools` module defines the following functions:
284284 class decorator supplies the rest. This simplifies the effort involved
285285 in specifying all of the possible rich comparison operations:
286286
287- The class must define one of :meth: `__lt__ `, :meth: `__le__ `,
288- :meth: `__gt__ `, or :meth: `__ge__ `.
289- In addition, the class should supply an :meth: `__eq__ ` method.
287+ The class must define one of :meth: `~object. __lt__ `, :meth: `~object. __le__ `,
288+ :meth: `~object. __gt__ `, or :meth: `~object. __ge__ `.
289+ In addition, the class should supply an :meth: `~object. __eq__ ` method.
290290
291291 For example::
292292
@@ -418,7 +418,7 @@ The :mod:`functools` module defines the following functions:
418418 like normal functions, are handled as descriptors).
419419
420420 When *func * is a descriptor (such as a normal Python function,
421- :func: `classmethod `, :func: `staticmethod `, :func: `abstractmethod ` or
421+ :func: `classmethod `, :func: `staticmethod `, :func: `~abc. abstractmethod ` or
422422 another instance of :class: `partialmethod `), calls to ``__get__ `` are
423423 delegated to the underlying descriptor, and an appropriate
424424 :ref: `partial object<partial-objects> ` returned as the result.
@@ -499,7 +499,7 @@ The :mod:`functools` module defines the following functions:
499499 ... print("Let me just say,", end=" ")
500500 ... print(arg)
501501
502- To add overloaded implementations to the function, use the :func: `register `
502+ To add overloaded implementations to the function, use the :func: `! register `
503503 attribute of the generic function, which can be used as a decorator. For
504504 functions annotated with types, the decorator will infer the type of the
505505 first argument automatically::
@@ -565,14 +565,14 @@ The :mod:`functools` module defines the following functions:
565565 runtime impact.
566566
567567 To enable registering :term: `lambdas<lambda> ` and pre-existing functions,
568- the :func: `register ` attribute can also be used in a functional form::
568+ the :func: `! register ` attribute can also be used in a functional form::
569569
570570 >>> def nothing(arg, verbose=False):
571571 ... print("Nothing.")
572572 ...
573573 >>> fun.register(type(None), nothing)
574574
575- The :func: `register ` attribute returns the undecorated function. This
575+ The :func: `! register ` attribute returns the undecorated function. This
576576 enables decorator stacking, :mod: `pickling<pickle> `, and the creation
577577 of unit tests for each variant independently::
578578
@@ -650,10 +650,10 @@ The :mod:`functools` module defines the following functions:
650650 .. versionadded :: 3.4
651651
652652 .. versionchanged :: 3.7
653- The :func: `register ` attribute now supports using type annotations.
653+ The :func: `! register ` attribute now supports using type annotations.
654654
655655 .. versionchanged :: 3.11
656- The :func: `register ` attribute now supports
656+ The :func: `! register ` attribute now supports
657657 :class: `typing.Union ` as a type annotation.
658658
659659
@@ -783,7 +783,7 @@ The :mod:`functools` module defines the following functions:
783783 'Docstring'
784784
785785 Without the use of this decorator factory, the name of the example function
786- would have been ``'wrapper' ``, and the docstring of the original :func: `example `
786+ would have been ``'wrapper' ``, and the docstring of the original :func: `! example `
787787 would have been lost.
788788
789789
0 commit comments