This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author Mark.Shannon
Recipients Demur Rumed, Mark.Shannon, benjamin.peterson, christian.heimes, mark.dickinson, nascheme, ncoghlan, pitrou, rhettinger, serhiy.storchaka, trent
Date 2018-01-02.17:13:35
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1514913215.86.0.467229070634.issue17611@psf.upfronthosting.co.za>
In-reply-to
Content
> It looks like the build core dumped on Travis-CI

I failed to account for the extra stuff left on the stack when handling exceptions and jumping out of a finally block due to a `break`. Caught by Serhiy's tests in https://github.com/python/cpython/pull/5078.
I could add a work around, but it would be a bit hacky.

I'm now convinced that code duplication is the only way to do this properly. The only real advantage of JSR-style finally blocks is the ease of implementation of `frame.set_lineno()`.

Rather than go around in circles any more, I suggest that we merge Serhiy's PR (PR 5006). I can then cherry-pick my commits to clean up the implementation of the `with` statement (as a new PR).

I then plan to implement `try-finally` using code duplication, but that might not make it into 3.7 and we shouldn't hold up this issue any longer.
History
Date User Action Args
2018-01-02 17:13:35Mark.Shannonsetrecipients: + Mark.Shannon, nascheme, rhettinger, mark.dickinson, ncoghlan, pitrou, christian.heimes, benjamin.peterson, trent, serhiy.storchaka, Demur Rumed
2018-01-02 17:13:35Mark.Shannonsetmessageid: <1514913215.86.0.467229070634.issue17611@psf.upfronthosting.co.za>
2018-01-02 17:13:35Mark.Shannonlinkissue17611 messages
2018-01-02 17:13:35Mark.Shannoncreate