mirror of
https://github.com/python/cpython.git
synced 2025-07-10 04:45:36 +00:00
[3.13] GH-116090: Fire RAISE events from _FOR_ITER_TIER_TWO (GH-122419)
(cherry picked from commit 15d4cd0967
)
This commit is contained in:
parent
56340ee8b1
commit
55554fd215
6 changed files with 14 additions and 12 deletions
|
@ -1037,7 +1037,7 @@ dummy_func(
|
|||
if (retval == NULL) {
|
||||
if (_PyErr_ExceptionMatches(tstate, PyExc_StopIteration)
|
||||
) {
|
||||
monitor_raise(tstate, frame, this_instr);
|
||||
_PyEval_MonitorRaise(tstate, frame, this_instr);
|
||||
}
|
||||
if (_PyGen_FetchStopIterationValue(&retval) == 0) {
|
||||
assert(retval != NULL);
|
||||
|
@ -2603,7 +2603,7 @@ dummy_func(
|
|||
if (!_PyErr_ExceptionMatches(tstate, PyExc_StopIteration)) {
|
||||
ERROR_NO_POP();
|
||||
}
|
||||
monitor_raise(tstate, frame, this_instr);
|
||||
_PyEval_MonitorRaise(tstate, frame, this_instr);
|
||||
_PyErr_Clear(tstate);
|
||||
}
|
||||
/* iterator ended normally */
|
||||
|
@ -2626,6 +2626,7 @@ dummy_func(
|
|||
if (!_PyErr_ExceptionMatches(tstate, PyExc_StopIteration)) {
|
||||
ERROR_NO_POP();
|
||||
}
|
||||
_PyEval_MonitorRaise(tstate, frame, frame->instr_ptr);
|
||||
_PyErr_Clear(tstate);
|
||||
}
|
||||
/* iterator ended normally */
|
||||
|
@ -2650,7 +2651,7 @@ dummy_func(
|
|||
if (!_PyErr_ExceptionMatches(tstate, PyExc_StopIteration)) {
|
||||
ERROR_NO_POP();
|
||||
}
|
||||
monitor_raise(tstate, frame, this_instr);
|
||||
_PyEval_MonitorRaise(tstate, frame, this_instr);
|
||||
_PyErr_Clear(tstate);
|
||||
}
|
||||
/* iterator ended normally */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue