[Python-checkins] bpo-41205: Document Decimal power 0 to the 0 (GH-21386)

Srinivas Reddy Thatiparthy (శ్రీనివాస్ రెడ్డి తాటిపర్తి) webhook-mailer at python.org
Sun Jul 19 07:03:49 EDT 2020


https://github.com/python/cpython/commit/10e466448f67850ed7bb2e2a4e7f017f2b050cad
commit: 10e466448f67850ed7bb2e2a4e7f017f2b050cad
branch: master
author: Srinivas Reddy Thatiparthy (శ్రీనివాస్  రెడ్డి తాటిపర్తి) <thatiparthysreenivas at gmail.com>
committer: GitHub <noreply at github.com>
date: 2020-07-19T13:03:43+02:00
summary:

bpo-41205: Document Decimal power 0 to the 0 (GH-21386)

Co-authored-by: Mark Dickinson <dickinsm at gmail.com>

files:
M Doc/library/decimal.rst

diff --git a/Doc/library/decimal.rst b/Doc/library/decimal.rst
index 38ad04177c5e8..e194649e30d85 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



More information about the Python-checkins mailing list