Skip to content

Commit

Permalink
Indicate that abs() method accept argument that implement __abs__(), …
Browse files Browse the repository at this point in the history
…just like call() method in the docs (GH-20509)
  • Loading branch information
Windsooon authored May 29, 2020
1 parent 21017ed commit 2831642
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions Doc/library/functions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,8 @@ are always available. They are listed here in alphabetical order.
.. function:: abs(x)

Return the absolute value of a number. The argument may be an
integer or a floating point number. If the argument is a complex number, its
magnitude is returned. If *x* defines :meth:`__abs__`,
``abs(x)`` returns ``x.__abs__()``.
integer, a floating point number, or an object implementing :meth:`__abs__`.
If the argument is a complex number, its magnitude is returned.


.. function:: all(iterable)
Expand Down

0 comments on commit 2831642

Please sign in to comment.