mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
perform yield from delegation by repeating YIELD_FROM opcode (closes #14230)
This allows generators that are using yield from to be seen by debuggers. It also kills the f_yieldfrom field on frame objects. Patch mostly from Mark Shannon with a few tweaks by me.
This commit is contained in:
parent
3270d11d8a
commit
2afe6aeae8
9 changed files with 113 additions and 166 deletions
|
@ -27,7 +27,6 @@ typedef struct _frame {
|
|||
to the current stack top. */
|
||||
PyObject **f_stacktop;
|
||||
PyObject *f_trace; /* Trace function */
|
||||
PyObject *f_yieldfrom; /* Iterator being delegated to by yield from */
|
||||
|
||||
/* In a generator, we need to be able to swap between the exception
|
||||
state inside the generator and the exception state of the calling
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue