From 10e466448f67850ed7bb2e2a4e7f017f2b050cad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Srinivas=20Reddy=20Thatiparthy=20=28=E0=B0=B6=E0=B1=8D?= =?UTF-8?q?=E0=B0=B0=E0=B1=80=E0=B0=A8=E0=B0=BF=E0=B0=B5=E0=B0=BE=E0=B0=B8?= =?UTF-8?q?=E0=B1=8D=20=20=E0=B0=B0=E0=B1=86=E0=B0=A1=E0=B1=8D=E0=B0=A1?= =?UTF-8?q?=E0=B0=BF=20=E0=B0=A4=E0=B0=BE=E0=B0=9F=E0=B0=BF=E0=B0=AA?= =?UTF-8?q?=E0=B0=B0=E0=B1=8D=E0=B0=A4=E0=B0=BF=29?= Date: Sun, 19 Jul 2020 16:33:43 +0530 Subject: [PATCH] bpo-41205: Document Decimal power 0 to the 0 (GH-21386) Co-authored-by: Mark Dickinson --- Doc/library/decimal.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Doc/library/decimal.rst b/Doc/library/decimal.rst index 38ad04177c5..e194649e30d 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