summaryrefslogtreecommitdiffstats
path: root/Lib/_pydecimal.py
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2021-06-12 12:15:17 (GMT)
committerGitHub <noreply@github.com>2021-06-12 12:15:17 (GMT)
commit9f1c5f6e8af6ba3f659b2aea1e221ac9695828ba (patch)
tree178272613398d4b75696f439134094b135a08f2a /Lib/_pydecimal.py
parent4a42cebf6dd769e2fa4e234a9e91093b3ad1cb63 (diff)
downloadcpython-9f1c5f6e8af6ba3f659b2aea1e221ac9695828ba.zip
cpython-9f1c5f6e8af6ba3f659b2aea1e221ac9695828ba.tar.gz
cpython-9f1c5f6e8af6ba3f659b2aea1e221ac9695828ba.tar.bz2
bpo-43475: Fix the Python implementation of hash of Decimal NaN (GH-26679)
Diffstat (limited to 'Lib/_pydecimal.py')
-rw-r--r--Lib/_pydecimal.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/_pydecimal.py b/Lib/_pydecimal.py
index ff23322..3d6cece 100644
--- a/Lib/_pydecimal.py
+++ b/Lib/_pydecimal.py
@@ -951,7 +951,7 @@ class Decimal(object):
if self.is_snan():
raise TypeError('Cannot hash a signaling NaN value.')
elif self.is_nan():
- return super().__hash__()
+ return object.__hash__(self)
else:
if self._sign:
return -_PyHASH_INF