aboutsummaryrefslogtreecommitdiff
path: root/tests/cmdline
diff options
context:
space:
mode:
authorDamien George2016-01-09 23:59:52 +0000
committerDamien George2017-02-16 18:38:06 +1100
commitf4df3aaa72a0460614b1ab8b7b8a7927a1165e31 (patch)
tree2c1ee2988630c79a4e79e40a15173af588d8fd2c /tests/cmdline
parentae8d86758631e62466a55d179897d2111c3cb1c1 (diff)
py: Allow bytecode/native to put iter_buf on stack for simple for loops.
So that the "for x in it: ..." statement can now work without using the heap (so long as the iterator argument fits in an iter_buf structure).
Diffstat (limited to 'tests/cmdline')
-rw-r--r--tests/cmdline/cmd_showbc.py.exp8
1 files changed, 6 insertions, 2 deletions
diff --git a/tests/cmdline/cmd_showbc.py.exp b/tests/cmdline/cmd_showbc.py.exp
index 1f0c054cf..8ee47eab6 100644
--- a/tests/cmdline/cmd_showbc.py.exp
+++ b/tests/cmdline/cmd_showbc.py.exp
@@ -31,7 +31,7 @@ File cmdline/cmd_showbc.py, code block 'f' (descriptor: \.\+, bytecode @\.\+ byt
Raw bytecode (code_info_size=\\d\+, bytecode_size=\\d\+):
########
\.\+rg names:
-(N_STATE 22)
+(N_STATE 23)
(N_EXC_STACK 2)
(INIT_CELL 14)
(INIT_CELL 15)
@@ -245,12 +245,16 @@ Raw bytecode (code_info_size=\\d\+, bytecode_size=\\d\+):
\\d\+ LOAD_FAST 0
\\d\+ STORE_FAST 0
\\d\+ LOAD_DEREF 14
-\\d\+ GET_ITER
+\\d\+ GET_ITER_STACK
\\d\+ FOR_ITER \\d\+
\\d\+ STORE_FAST 0
\\d\+ LOAD_FAST 1
\\d\+ POP_TOP
\\d\+ JUMP \\d\+
+\\d\+ POP_TOP
+\\d\+ POP_TOP
+\\d\+ POP_TOP
+\\d\+ POP_TOP
\\d\+ SETUP_FINALLY \\d\+
\\d\+ SETUP_EXCEPT \\d\+
\\d\+ JUMP \\d\+