diff options
author | Mark Dickinson <dickinsm@gmail.com> | 2009-10-17 07:06:37 +0000 |
---|---|---|
committer | Mark Dickinson <dickinsm@gmail.com> | 2009-10-17 07:06:37 +0000 |
commit | 59ca92093c548af1acb4bc3e9e9dc3649ece513d (patch) | |
tree | 3fb162ec72ef21faf9422472a3ab829d814e1c07 /Lib/test | |
parent | 0447cd6fdc9b7d179c729fb43df55eeab8173dcc (diff) | |
download | cpython-git-59ca92093c548af1acb4bc3e9e9dc3649ece513d.tar.gz |
test_math ulp computation was wrong on big-endian systems
Diffstat (limited to 'Lib/test')
-rw-r--r-- | Lib/test/test_math.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_math.py b/Lib/test/test_math.py index 2f45a1ea3c..41c2f4fe47 100644 --- a/Lib/test/test_math.py +++ b/Lib/test/test_math.py @@ -43,7 +43,7 @@ def to_ulps(x): where C doubles are represented in IEEE 754 binary64 format. """ - n = struct.unpack('q', struct.pack('<d', x))[0] + n = struct.unpack('<q', struct.pack('<d', x))[0] if n < 0: n = ~(n+2**63) return n |