mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
bpo-43693: Add _PyCode_New(). (gh-26375)
This is an internal-only API that helps us manage the many values used to create a code object. https://bugs.python.org/issue43693
This commit is contained in:
parent
318adeba78
commit
9f494d4929
12 changed files with 4736 additions and 4648 deletions
|
@ -354,6 +354,7 @@ _code_type = type(_write_atomic.__code__)
|
|||
# Python 3.10b1 3439 (Add ROT_N)
|
||||
# Python 3.11a1 3450 Use exception table for unwinding ("zero cost" exception handling)
|
||||
# Python 3.11a1 3451 (Add CALL_METHOD_KW)
|
||||
# Python 3.11a1 3452 (drop nlocals from marshaled code objects)
|
||||
|
||||
#
|
||||
# MAGIC must change whenever the bytecode emitted by the compiler may no
|
||||
|
@ -363,7 +364,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 = (3451).to_bytes(2, 'little') + b'\r\n'
|
||||
MAGIC_NUMBER = (3452).to_bytes(2, 'little') + b'\r\n'
|
||||
_RAW_MAGIC_NUMBER = int.from_bytes(MAGIC_NUMBER, 'little') # For import.c
|
||||
|
||||
_PYCACHE = '__pycache__'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue