Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 754fd74 commit 0e7a692Copy full SHA for 0e7a692
Objects/genobject.c
@@ -10,6 +10,7 @@
10
#include "pycore_modsupport.h" // _PyArg_CheckPositional()
11
#include "pycore_object.h" // _PyObject_GC_UNTRACK()
12
#include "pycore_opcode_metadata.h" // _PyOpcode_Caches
13
+#include "pycore_opcode_utils.h" // RESUME_AFTER_YIELD_FROM
14
#include "pycore_pyerrors.h" // _PyErr_ClearExcState()
15
#include "pycore_pystate.h" // _PyThreadState_GET()
16
@@ -363,7 +364,7 @@ _PyGen_yf(PyGenObject *gen)
363
364
assert(_PyCode_CODE(_PyGen_GetCode(gen))[0].op.code != SEND);
365
return NULL;
366
}
- if (!is_resume(frame->instr_ptr) || frame->instr_ptr->op.arg < 2)
367
+ if (!is_resume(frame->instr_ptr) || frame->instr_ptr->op.arg < RESUME_AFTER_YIELD_FROM)
368
{
369
/* Not in a yield from */
370
0 commit comments