summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2013-11-19 22:03:25 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2013-11-19 22:03:25 (GMT)
commit85fe8a645e06d54d9b5dfc24375cc9231bff7e00 (patch)
treefce0625e255641a55f6d9f03698b3345f29b62db
parentb679a2eb781091b497fabc8493d7ba33d57ebf41 (diff)
downloadcpython-85fe8a645e06d54d9b5dfc24375cc9231bff7e00.zip
cpython-85fe8a645e06d54d9b5dfc24375cc9231bff7e00.tar.gz
cpython-85fe8a645e06d54d9b5dfc24375cc9231bff7e00.tar.bz2
Issue #9566, #19617: New try to fix compilation on Windows
Some compilers (ex: Visual Studio) decode -2147483648 as a unsigned integer instead of an signed integer.
-rw-r--r--Python/compile.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/compile.c b/Python/compile.c
index 2c8db48..78841d3 100644
--- a/Python/compile.c
+++ b/Python/compile.c
@@ -1183,7 +1183,7 @@ compiler_addop_i(struct compiler *c, Py_ssize_t opcode, Py_ssize_t oparg)
/* Integer arguments are limit to 16-bit. There is an extension for 32-bit
integer arguments. */
- assert(-2147483648 <= opcode);
+ assert((-2147483647-1) <= opcode);
assert(opcode <= 2147483647);
off = compiler_next_instr(c, c->u->u_curblock);