mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
Issue #15477: Add workaround for log1p(-0.0) on platforms where it's broken.
This commit is contained in:
parent
31a11902b3
commit
05d79e9abf
4 changed files with 28 additions and 10 deletions
|
@ -519,15 +519,11 @@ class CMathTests(unittest.TestCase):
|
|||
# of zero, then atan and atanh will also have difficulties with
|
||||
# the sign of complex zeros.
|
||||
@requires_IEEE_754
|
||||
@unittest.skipIf(sysconfig.get_config_var('LOG1P_DROPS_ZERO_SIGN'),
|
||||
"system log1p() function doesn't preserve the sign")
|
||||
def testAtanSign(self):
|
||||
for z in complex_zeros:
|
||||
self.assertComplexIdentical(cmath.atan(z), z)
|
||||
|
||||
@requires_IEEE_754
|
||||
@unittest.skipIf(sysconfig.get_config_var('LOG1P_DROPS_ZERO_SIGN'),
|
||||
"system log1p() function doesn't preserve the sign")
|
||||
def testAtanhSign(self):
|
||||
for z in complex_zeros:
|
||||
self.assertComplexIdentical(cmath.atanh(z), z)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue