summaryrefslogtreecommitdiffstats
path: root/Python/opcode_targets.h
diff options
context:
space:
mode:
authorJelle Zijlstra <jelle.zijlstra@gmail.com>2024-05-22 00:46:39 (GMT)
committerGitHub <noreply@github.com>2024-05-22 00:46:39 (GMT)
commit98e855fcc1f1d490c803565e84cb611b3f057e45 (patch)
tree53f19fb0244fa8c43e53534c31842adf5b65ebc2 /Python/opcode_targets.h
parent506b1a3ff66a41c72d205c8e4cba574e439d8e76 (diff)
downloadcpython-98e855fcc1f1d490c803565e84cb611b3f057e45.zip
cpython-98e855fcc1f1d490c803565e84cb611b3f057e45.tar.gz
cpython-98e855fcc1f1d490c803565e84cb611b3f057e45.tar.bz2
gh-119180: Add LOAD_COMMON_CONSTANT opcode (#119321)
The PEP 649 implementation will require a way to load NotImplementedError from the bytecode. @markshannon suggested implementing this by converting LOAD_ASSERTION_ERROR into a more general mechanism for loading constants. This PR adds this new opcode. I will work on the rest of the implementation of the PEP separately. Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
Diffstat (limited to 'Python/opcode_targets.h')
-rw-r--r--Python/opcode_targets.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/opcode_targets.h b/Python/opcode_targets.h
index fa4f1f8..322483f 100644
--- a/Python/opcode_targets.h
+++ b/Python/opcode_targets.h
@@ -22,7 +22,6 @@ static void *opcode_targets[256] = {
&&TARGET_GET_LEN,
&&TARGET_GET_YIELD_FROM_ITER,
&&TARGET_INTERPRETER_EXIT,
- &&TARGET_LOAD_ASSERTION_ERROR,
&&TARGET_LOAD_BUILD_CLASS,
&&TARGET_LOAD_LOCALS,
&&TARGET_MAKE_FUNCTION,
@@ -82,6 +81,7 @@ static void *opcode_targets[256] = {
&&TARGET_LIST_APPEND,
&&TARGET_LIST_EXTEND,
&&TARGET_LOAD_ATTR,
+ &&TARGET_LOAD_COMMON_CONSTANT,
&&TARGET_LOAD_CONST,
&&TARGET_LOAD_DEREF,
&&TARGET_LOAD_FAST,