Erik Bray added the comment: Actually I just finished reading njs's blog post, and as he points out that special case for SETUP_FINALLY is basically broken. There are other cases where it doesn't really work either. For example if you have:
if ...: do_something() else: do_something_else() try: ... finally: ... then (ignoring the issue about POP_TOP for a moment) the last instruction in *one* of these branches if followed immediately by SETUP_FINALLY, while in the other branch there's a JUMP_FORWARD, then the SETUP_FINALLY. All the more reason for a more generic solution to this that doesn't depend strictly on the next op locally in the byte code. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue29988> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com