From faa3272fb8d63d481a136cc0467a0cba6ed7b264 Mon Sep 17 00:00:00 2001 From: Mark Shannon Date: Tue, 29 Oct 2024 11:15:42 +0000 Subject: GH-125837: Split `LOAD_CONST` into three. (GH-125972) * Add LOAD_CONST_IMMORTAL opcode * Add LOAD_SMALL_INT opcode * Remove RETURN_CONST opcode --- Lib/test/test_code.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Lib/test/test_code.py') diff --git a/Lib/test/test_code.py b/Lib/test/test_code.py index 93f3a5833cb..dcdd15a43e6 100644 --- a/Lib/test/test_code.py +++ b/Lib/test/test_code.py @@ -254,10 +254,11 @@ class CodeTest(unittest.TestCase): return x code = func.__code__ - # different co_name, co_varnames, co_consts + # Different co_name, co_varnames, co_consts. + # Must have the same number of constants and + # variables or we get crashes. def func2(): y = 2 - z = 3 return y code2 = func2.__code__ -- cgit v1.2.3