Skip to content
5 changes: 5 additions & 0 deletions Doc/library/functools.rst
Original file line number Diff line number Diff line change
Expand Up @@ -692,6 +692,11 @@
@neg.register
def _(self, arg: bool):
return not arg
.. note::

Check warning on line 695 in Doc/library/functools.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

Literal block ends without a blank line; unexpected unindent. [docutils]
Comment thread
johnslavik marked this conversation as resolved.
Outdated
``singledispatchmethod`` dispatches the first argument during call
time irrespective of whether the method is bound or unbound, as a result,
``x.f(a) != C.f(x, a)``.The behavior is intentional and required to support correct dispatch for

Check warning on line 698 in Doc/library/functools.rst

View workflow job for this annotation

GitHub Actions / Docs / Docs

Block quote ends without a blank line; unexpected unindent. [docutils]
``staticmethod`` and ``classmethod``.

``@singledispatchmethod`` supports nesting with other decorators such as
:deco:`classmethod`. Note that to allow for
Expand Down
Loading