Neil Schemenauer <nas-pyt...@arctrix.com> added the comment:

On 2017-12-29, Mark Shannon wrote:
> One point I didn't cover is jumping to a new line in the debugger.
> Implementing that reliably for finally blocks with code
> duplication is tricky and would mean adding a number of marker
> bytecodes.  Which is a big point in favour of the JSR style.

Could we virtually execute the code, forwards or backwards,
starting from f_lasti?  For conditional jumps, we would follow both
branches.  Stop when we find the line number we want.  If we hit an
opcode that causes a fblock push or pop, abort.

I started implementing this as a proof of concept but didn't finish.
It seems to fit most naturally as an exported function of
Python/peephole.c.  That file already does a lot of similar stuff.

----------

_______________________________________
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

Reply via email to