mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
More NaN consistency doc fixes.
This commit is contained in:
parent
e07acb5f15
commit
ad971d62ee
1 changed files with 3 additions and 3 deletions
|
@ -375,9 +375,9 @@ Constants
|
||||||
:exc:`ValueError` for invalid operations like ``sqrt(-1.0)`` or ``log(0.0)``
|
:exc:`ValueError` for invalid operations like ``sqrt(-1.0)`` or ``log(0.0)``
|
||||||
(where C99 Annex F recommends signaling invalid operation or divide-by-zero),
|
(where C99 Annex F recommends signaling invalid operation or divide-by-zero),
|
||||||
and :exc:`OverflowError` for results that overflow (for example,
|
and :exc:`OverflowError` for results that overflow (for example,
|
||||||
``exp(1000.0)``). A *NaN* will not be returned from any of the functions
|
``exp(1000.0)``). A NaN will not be returned from any of the functions
|
||||||
above unless one or more of the input arguments was a *NaN*; in that case,
|
above unless one or more of the input arguments was a NaN; in that case,
|
||||||
most functions will return a *NaN*, but (again following C99 Annex F) there
|
most functions will return a NaN, but (again following C99 Annex F) there
|
||||||
are some exceptions to this rule, for example ``pow(float('nan'), 0.0)`` or
|
are some exceptions to this rule, for example ``pow(float('nan'), 0.0)`` or
|
||||||
``hypot(float('nan'), float('inf'))``.
|
``hypot(float('nan'), float('inf'))``.
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue