summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_compile.py
diff options
context:
space:
mode:
authorNeal Norwitz <nnorwitz@gmail.com>2003-02-18 15:22:10 (GMT)
committerNeal Norwitz <nnorwitz@gmail.com>2003-02-18 15:22:10 (GMT)
commiteb2a5ef36a790ccd3d6943cd75c81fc289fc55c6 (patch)
tree8573507c148b518ce35b1ada29192f60d1913b8e /Lib/test/test_compile.py
parent4edaa0d516dc6b5e3d739e45d55226bef8516512 (diff)
downloadcpython-eb2a5ef36a790ccd3d6943cd75c81fc289fc55c6.zip
cpython-eb2a5ef36a790ccd3d6943cd75c81fc289fc55c6.tar.gz
cpython-eb2a5ef36a790ccd3d6943cd75c81fc289fc55c6.tar.bz2
Fix SF bug #688424, 64-bit test problems
Diffstat (limited to 'Lib/test/test_compile.py')
-rw-r--r--Lib/test/test_compile.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/Lib/test/test_compile.py b/Lib/test/test_compile.py
index 1812fbc..2281b37 100644
--- a/Lib/test/test_compile.py
+++ b/Lib/test/test_compile.py
@@ -145,9 +145,14 @@ expect_same("000000000000009.", 9.)
# Verify treatment of unary minus on negative numbers SF bug #660455
import warnings
warnings.filterwarnings("ignore", "hex/oct constants", FutureWarning)
+warnings.filterwarnings("ignore", "hex.* of negative int", FutureWarning)
# XXX Of course the following test will have to be changed in Python 2.4
# This test is in a <string> so the filterwarnings() can affect it
+import sys
+all_one_bits = '0xffffffff'
+if sys.maxint != 2147483647:
+ all_one_bits = '0xffffffffffffffff'
exec """
-expect_same("0xffffffff", -1)
-expect_same("-0xffffffff", 1)
+expect_same(all_one_bits, -1)
+expect_same("-" + all_one_bits, 1)
"""