summaryrefslogtreecommitdiffstats
path: root/Include/opcode.h
diff options
context:
space:
mode:
authorJelle Zijlstra <jelle.zijlstra@gmail.com>2023-05-16 03:36:23 (GMT)
committerGitHub <noreply@github.com>2023-05-16 03:36:23 (GMT)
commit24d8b88420b81fc60aeb0cbcacef1e72d633824a (patch)
tree1b06e157ddc7d1066fd41a28d2c27270ccf2e278 /Include/opcode.h
parentfdafdc235e74f2f4fedc1f745bf8b90141daa162 (diff)
downloadcpython-24d8b88420b81fc60aeb0cbcacef1e72d633824a.zip
cpython-24d8b88420b81fc60aeb0cbcacef1e72d633824a.tar.gz
cpython-24d8b88420b81fc60aeb0cbcacef1e72d633824a.tar.bz2
gh-103763: Implement PEP 695 (#103764)
This implements PEP 695, Type Parameter Syntax. It adds support for: - Generic functions (def func[T](): ...) - Generic classes (class X[T](): ...) - Type aliases (type X = ...) - New scoping when the new syntax is used within a class body - Compiler and interpreter changes to support the new syntax and scoping rules Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com> Co-authored-by: Eric Traut <eric@traut.com> Co-authored-by: Larry Hastings <larry@hastings.org> Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Diffstat (limited to 'Include/opcode.h')
-rw-r--r--Include/opcode.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/Include/opcode.h b/Include/opcode.h
index c3b6e5d..dea7687 100644
--- a/Include/opcode.h
+++ b/Include/opcode.h
@@ -45,6 +45,7 @@ extern "C" {
#define RETURN_GENERATOR 75
#define RETURN_VALUE 83
#define SETUP_ANNOTATIONS 85
+#define LOAD_LOCALS 87
#define POP_EXCEPT 89
#define HAVE_ARGUMENT 90
#define STORE_NAME 90
@@ -102,7 +103,6 @@ extern "C" {
#define LIST_APPEND 145
#define SET_ADD 146
#define MAP_ADD 147
-#define LOAD_CLASSDEREF 148
#define COPY_FREE_VARS 149
#define YIELD_VALUE 150
#define RESUME 151
@@ -118,6 +118,8 @@ extern "C" {
#define KW_NAMES 172
#define CALL_INTRINSIC_1 173
#define CALL_INTRINSIC_2 174
+#define LOAD_FROM_DICT_OR_GLOBALS 175
+#define LOAD_FROM_DICT_OR_DEREF 176
#define MIN_INSTRUMENTED_OPCODE 238
#define INSTRUMENTED_POP_JUMP_IF_NONE 238
#define INSTRUMENTED_POP_JUMP_IF_NOT_NONE 239
@@ -199,11 +201,11 @@ extern "C" {
#define LOAD_ATTR_METHOD_WITH_VALUES 82
#define LOAD_CONST__LOAD_FAST 84
#define LOAD_FAST__LOAD_CONST 86
-#define LOAD_FAST__LOAD_FAST 87
-#define LOAD_GLOBAL_BUILTIN 88
-#define LOAD_GLOBAL_MODULE 111
-#define STORE_ATTR_INSTANCE_VALUE 112
-#define STORE_ATTR_SLOT 113
+#define LOAD_FAST__LOAD_FAST 88
+#define LOAD_GLOBAL_BUILTIN 111
+#define LOAD_GLOBAL_MODULE 112
+#define STORE_ATTR_INSTANCE_VALUE 113
+#define STORE_ATTR_SLOT 148
#define STORE_ATTR_WITH_HINT 153
#define STORE_FAST__LOAD_FAST 154
#define STORE_FAST__STORE_FAST 158