Author: Armin Rigo <ar...@tunes.org>
Branch: 
Changeset: r79874:650fe2c7926c
Date: 2015-09-28 09:07 +0200
http://bitbucket.org/pypy/pypy/changeset/650fe2c7926c/

Log:    Avoid two large constants

diff --git a/pypy/objspace/std/floatobject.py b/pypy/objspace/std/floatobject.py
--- a/pypy/objspace/std/floatobject.py
+++ b/pypy/objspace/std/floatobject.py
@@ -123,7 +123,7 @@
             f1 = self.floatval
             i2 = space.int_w(w_other)
             # (double-)floats have always at least 48 bits of precision
-            if LONG_BIT > 32 and not int_between((-1)<<48, i2, 1<<48):
+            if LONG_BIT > 32 and not int_between(-1, i2 >> 48, 1):
                 res = do_compare_bigint(f1, rbigint.fromint(i2))
             else:
                 f2 = float(i2)
_______________________________________________
pypy-commit mailing list
pypy-commit@python.org
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to