summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_compiler_codegen.py
diff options
context:
space:
mode:
authorIrit Katriel <1055913+iritkatriel@users.noreply.github.com>2023-05-07 17:47:28 (GMT)
committerGitHub <noreply@github.com>2023-05-07 17:47:28 (GMT)
commit2c2dc61e8d01f44e5b7e63dd99196460a80905f1 (patch)
tree37ca8931151f7ec65d3a5ed28d39bc4bdd956b2e /Lib/test/test_compiler_codegen.py
parent1b19bd1a88e6c410fc9cd08db48e0d35cfa8bb5a (diff)
downloadcpython-2c2dc61e8d01f44e5b7e63dd99196460a80905f1.zip
cpython-2c2dc61e8d01f44e5b7e63dd99196460a80905f1.tar.gz
cpython-2c2dc61e8d01f44e5b7e63dd99196460a80905f1.tar.bz2
gh-104240: make _PyCompile_CodeGen support different compilation modes (#104241)
Diffstat (limited to 'Lib/test/test_compiler_codegen.py')
-rw-r--r--Lib/test/test_compiler_codegen.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/test/test_compiler_codegen.py b/Lib/test/test_compiler_codegen.py
index 022753e..ea57df9 100644
--- a/Lib/test/test_compiler_codegen.py
+++ b/Lib/test/test_compiler_codegen.py
@@ -25,6 +25,8 @@ class IsolatedCodeGenTests(CodegenTestCase):
('LOAD_CONST', 2, 1),
exit_lbl,
('POP_TOP', None),
+ ('LOAD_CONST', 3),
+ ('RETURN_VALUE', None),
]
self.codegen_test(snippet, expected)
@@ -46,5 +48,7 @@ class IsolatedCodeGenTests(CodegenTestCase):
('JUMP', loop_lbl),
exit_lbl,
('END_FOR', None),
+ ('LOAD_CONST', 0),
+ ('RETURN_VALUE', None),
]
self.codegen_test(snippet, expected)