diff options
author | Srinivas Reddy Thatiparthy (శ్రీనివాస్ రెడ్డి తాటిపర్తి) <thatiparthysreenivas@gmail.com> | 2020-07-19 11:03:43 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-19 11:03:43 (GMT) |
commit | 10e466448f67850ed7bb2e2a4e7f017f2b050cad (patch) | |
tree | ec3e61d6c0b718e12e606d776751ed0c58683ae0 /Doc/library | |
parent | 6bf3237379b17632db52cb39d181e8bac70173f3 (diff) | |
download | cpython-10e466448f67850ed7bb2e2a4e7f017f2b050cad.zip cpython-10e466448f67850ed7bb2e2a4e7f017f2b050cad.tar.gz cpython-10e466448f67850ed7bb2e2a4e7f017f2b050cad.tar.bz2 |
bpo-41205: Document Decimal power 0 to the 0 (GH-21386)
Co-authored-by: Mark Dickinson <dickinsm@gmail.com>
Diffstat (limited to 'Doc/library')
-rw-r--r-- | Doc/library/decimal.rst | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Doc/library/decimal.rst b/Doc/library/decimal.rst index 38ad041..e194649 100644 --- a/Doc/library/decimal.rst +++ b/Doc/library/decimal.rst @@ -1357,6 +1357,9 @@ In addition to the three supplied contexts, new contexts can be created with the The rounding mode of the context is used. Results are always correctly-rounded in the Python version. + ``Decimal(0) ** Decimal(0)`` results in ``InvalidOperation``, and if ``InvalidOperation`` + is not trapped, then results in ``Decimal('NaN')``. + .. versionchanged:: 3.3 The C module computes :meth:`power` in terms of the correctly-rounded :meth:`exp` and :meth:`ln` functions. The result is well-defined but |