diff options
author | Damien George <damien.p.george@gmail.com> | 2017-05-25 20:39:08 +1000 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2017-05-25 20:39:08 +1000 |
commit | 04d05db27ec4a160dcb3d3ff2934184fef455dbf (patch) | |
tree | efe7b96b8f3d135b73f352a5c989ea280c31ccd4 /py | |
parent | 68e71eacb8f5e67f9765ccd8639ca359bc3417de (diff) | |
download | micropython-04d05db27ec4a160dcb3d3ff2934184fef455dbf.tar.gz micropython-04d05db27ec4a160dcb3d3ff2934184fef455dbf.zip |
py/vm: Fix bug with unwind jump popping the iterator from a for loop.
This patch fixes a regression introduced by
088740ecc40476fd0796a3ef6a68ee7c677eae64
Diffstat (limited to 'py')
-rw-r--r-- | py/vm.c | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -690,8 +690,7 @@ unwind_jump:; } ip = (const byte*)MP_OBJ_TO_PTR(POP()); // pop destination ip for jump if (unum != 0) { - // pop iter and iter_buf - sp--; + // pop the exhausted iterator sp -= MP_OBJ_ITER_BUF_NSLOTS; } DISPATCH_WITH_PEND_EXC_CHECK(); |