summaryrefslogtreecommitdiffstats
path: root/Lib/importlib/_bootstrap_external.py
diff options
context:
space:
mode:
authorMark Shannon <mark@hotpy.org>2022-05-19 16:49:29 (GMT)
committerGitHub <noreply@github.com>2022-05-19 16:49:29 (GMT)
commit3fd86100022103f41ada043f5bb5a7201e80ac27 (patch)
treed57d89cce134d2556a64ea1935117aa2729fedad /Lib/importlib/_bootstrap_external.py
parent70aa1b9b912d8254df3c61ae0a55464962f4c087 (diff)
downloadcpython-3fd86100022103f41ada043f5bb5a7201e80ac27.zip
cpython-3fd86100022103f41ada043f5bb5a7201e80ac27.tar.gz
cpython-3fd86100022103f41ada043f5bb5a7201e80ac27.tar.bz2
GH-89914: Make the oparg of the YIELD_VALUE instruction equal the stack depth. (GH-92960)
Diffstat (limited to 'Lib/importlib/_bootstrap_external.py')
-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 e7941ae..eac371f 100644
--- a/Lib/importlib/_bootstrap_external.py
+++ b/Lib/importlib/_bootstrap_external.py
@@ -405,6 +405,7 @@ _code_type = type(_write_atomic.__code__)
# Python 3.11a7 3494 (New location info table)
# Python 3.12a1 3500 (Remove PRECALL opcode)
+# Python 3.12a1 3501 (YIELD_VALUE oparg == stack_depth)
# Python 3.13 will start with 3550
@@ -418,7 +419,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 = (3500).to_bytes(2, 'little') + b'\r\n'
+MAGIC_NUMBER = (3501).to_bytes(2, 'little') + b'\r\n'
_RAW_MAGIC_NUMBER = int.from_bytes(MAGIC_NUMBER, 'little') # For import.c