[pypy-svn] r52228 - pypy/branch/jit-refactoring/pypy/jit/rainbow
arigo at codespeak.net
arigo at codespeak.net
Thu Mar 6 19:27:16 CET 2008
Author: arigo
Date: Thu Mar 6 19:27:15 2008
New Revision: 52228
Modified:
pypy/branch/jit-refactoring/pypy/jit/rainbow/codewriter.py
Log:
Catching this problem early looks like an excellent idea.
Modified: pypy/branch/jit-refactoring/pypy/jit/rainbow/codewriter.py
==============================================================================
--- pypy/branch/jit-refactoring/pypy/jit/rainbow/codewriter.py (original)
+++ pypy/branch/jit-refactoring/pypy/jit/rainbow/codewriter.py Thu Mar 6 19:27:15 2008
@@ -1482,6 +1482,7 @@
def assemble_labelpos(labelpos, interpreter, *args):
result = []
def emit_2byte(index):
+ assert -32768 <= index < 32767
result.append(chr((index >> 8) & 0xff))
result.append(chr(index & 0xff))
for arg in args:
More information about the Pypy-commit
mailing list