summaryrefslogtreecommitdiffstats
path: root/Lib/importlib
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2016-05-24 06:15:14 (GMT)
committerSerhiy Storchaka <storchaka@gmail.com>2016-05-24 06:15:14 (GMT)
commitb0f80b0312a99ca46323efc0e4d09b567553ed46 (patch)
tree323c414ce867d58fe60e127b4275e9931855a72f /Lib/importlib
parentc35f491a06bb55cba097ddcd9fcbc9452ec21fb1 (diff)
downloadcpython-b0f80b0312a99ca46323efc0e4d09b567553ed46.zip
cpython-b0f80b0312a99ca46323efc0e4d09b567553ed46.tar.gz
cpython-b0f80b0312a99ca46323efc0e4d09b567553ed46.tar.bz2
Issue #26647: Python interpreter now uses 16-bit wordcode instead of bytecode.
Patch by Demur Rumed.
Diffstat (limited to 'Lib/importlib')
-rw-r--r--Lib/importlib/_bootstrap_external.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/importlib/_bootstrap_external.py b/Lib/importlib/_bootstrap_external.py
index 076ed16..1388618 100644
--- a/Lib/importlib/_bootstrap_external.py
+++ b/Lib/importlib/_bootstrap_external.py
@@ -225,6 +225,7 @@ _code_type = type(_write_atomic.__code__)
# Python 3.5b2 3350 (add GET_YIELD_FROM_ITER opcode #24400)
# Python 3.6a0 3360 (add FORMAT_VALUE opcode #25483
# Python 3.6a0 3361 (lineno delta of code.co_lnotab becomes signed)
+# Python 3.6a0 3370 (16 bit wordcode)
#
# MAGIC must change whenever the bytecode emitted by the compiler may no
# longer be understood by older implementations of the eval loop (usually
@@ -233,7 +234,7 @@ _code_type = type(_write_atomic.__code__)
# Whenever MAGIC_NUMBER is changed, the ranges in the magic_values array
# in PC/launcher.c must also be updated.
-MAGIC_NUMBER = (3361).to_bytes(2, 'little') + b'\r\n'
+MAGIC_NUMBER = (3370).to_bytes(2, 'little') + b'\r\n'
_RAW_MAGIC_NUMBER = int.from_bytes(MAGIC_NUMBER, 'little') # For import.c
_PYCACHE = '__pycache__'