summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_long.py
diff options
context:
space:
mode:
authorMark Dickinson <dickinsm@gmail.com>2009-12-27 19:03:31 (GMT)
committerMark Dickinson <dickinsm@gmail.com>2009-12-27 19:03:31 (GMT)
commita4e1506e7f6a39c5226f08847d041568be1140e2 (patch)
treea80a202f1e9a97a141e3f21c0f44abb667503dfc /Lib/test/test_long.py
parentcbb62745acc34e7f6ac27a6eb3fb6a5858494d5f (diff)
downloadcpython-a4e1506e7f6a39c5226f08847d041568be1140e2.zip
cpython-a4e1506e7f6a39c5226f08847d041568be1140e2.tar.gz
cpython-a4e1506e7f6a39c5226f08847d041568be1140e2.tar.bz2
Merged revisions 77066 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r77066 | mark.dickinson | 2009-12-27 16:16:02 +0000 (Sun, 27 Dec 2009) | 1 line Use ldexp(q, exp) instead of q*2.**exp in true division test, to avoid bogus failures on platforms with broken pow (e.g., Ubuntu/ia64). ........
Diffstat (limited to 'Lib/test/test_long.py')
-rw-r--r--Lib/test/test_long.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_long.py b/Lib/test/test_long.py
index 98221e6..4096f1f 100644
--- a/Lib/test/test_long.py
+++ b/Lib/test/test_long.py
@@ -73,7 +73,7 @@ def truediv(a, b):
if 2*r > b or 2*r == b and q % 2 == 1:
q += 1
- result = float(q) * 2.**exp
+ result = math.ldexp(q, exp)
return -result if negative else result