Skip to content

Commit 1dda505

Browse files
cleanup
1 parent fb1cc3f commit 1dda505

File tree

4 files changed

+13
-19
lines changed

4 files changed

+13
-19
lines changed

Python/bytecodes.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5208,6 +5208,10 @@ dummy_func(
52085208
if (lltrace < 0) {
52095209
goto exit_unwind;
52105210
}
5211+
/* _PyEval_EvalFrameDefault() must not be called with an exception set,
5212+
because it can clear it (directly or indirectly) and so the
5213+
caller loses its exception */
5214+
assert(!_PyErr_Occurred(tstate));
52115215
#endif
52125216
#if defined(Py_TAIL_CALL_INTERP) && !defined(IN_TAIL_CALL_INTERP)
52135217
return _TAIL_CALL_entry(frame, stack_pointer, tstate, next_instr, 0, 0);

Python/ceval.c

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -865,27 +865,9 @@ _PyEval_EvalFrameDefault(PyThreadState *tstate, _PyInterpreterFrame *frame, int
865865
const _PyUOpInstruction *next_uop = NULL;
866866
#endif
867867

868-
if (_Py_EnterRecursivePy(tstate)) {
869-
goto exit_unwind;
870-
}
871-
872-
next_instr = frame->instr_ptr;
873-
stack_pointer = _PyFrame_GetStackPointer(frame);
874868

875-
LLTRACE_RESUME_FRAME();
876-
877-
#ifdef Py_DEBUG
878-
/* _PyEval_EvalFrameDefault() must not be called with an exception set,
879-
because it can clear it (directly or indirectly) and so the
880-
caller loses its exception */
881-
assert(!_PyErr_Occurred(tstate));
882-
#endif
869+
goto start_frame;
883870

884-
#ifdef Py_TAIL_CALL_INTERP
885-
return _TAIL_CALL_entry(frame, stack_pointer, tstate, next_instr, 0, 0);
886-
#else
887-
DISPATCH();
888-
#endif
889871

890872
#include "generated_cases.c.h"
891873

Python/generated_cases.c.h

Lines changed: 4 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Python/generated_tail_call_handlers.c.h

Lines changed: 4 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)