Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Make the explanation more precise.
  • Loading branch information
elena
elena committed Sep 7, 2017
commit ac9f872644fdc5571b9933e2b9fd2cc2eb96d4aa
5 changes: 3 additions & 2 deletions Doc/library/functions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1311,8 +1311,9 @@ are always available. They are listed here in alphabetical order.
negative). The return value is an integer if *ndigits* is omitted or is ``None``.
Otherwise the return value has the same type as *number*.

For a general Python object ``number``, ``round`` delegates to
``number.__round__``.
For a general Python object, ``round(number)`` or ``round(number, None)``
delegates to ``number.__round__()``, and ``round(number, ndigits)`` delegates
to ``number.__round__(ndigits)``.

.. note::

Expand Down