Serhiy Storchaka <storchaka+cpyt...@gmail.com> added the comment: > The problem is that makes the stack consumption of END_FINALLY variable. > How about always consuming 6 items, even when most of them are unused > padding?
Right. Though the value of the stack increment makes sense only for the case 1, because in other cases the next executed instruction is not the one following END_FINALLY, but we need to reserve the stack for the case 3, and counting additional "virtual" items in PUSH_NO_EXCEPT and END_FINALLY will help to calculate the maximal stack consumption, even when in runtime they push/pop only one item. This is yet one argument for special purposed opcode PUSH_NO_EXCEPT (maybe I'll rename it to START_FINALLY or BEGIN_FINALLY). Other reason -- this will help to determine bounds of finally blocks in the frame.f_lineno setter. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue17611> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com