Skip to content

Commit 01f2288

Browse files
committed
INTERPRETER_EXIT (a bit weird, ends in return)
1 parent 11b5e57 commit 01f2288

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

Python/bytecodes.c

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ do { \
8282
static PyObject *value, *value1, *value2, *left, *right, *res, *sum, *prod, *sub;
8383
static PyObject *container, *start, *stop, *v, *lhs, *rhs;
8484
static PyObject *list, *tuple, *dict, *owner;
85-
static PyObject *exit_func, *lasti, *val;
85+
static PyObject *exit_func, *lasti, *val, *retval;
8686
static size_t jump;
8787
// Dummy variables for cache effects
8888
static _Py_CODEUNIT when_to_jump_mask, invert, counter, index, hint;
@@ -584,11 +584,10 @@ dummy_func(
584584
goto error;
585585
}
586586

587-
// stack effect: (__0 -- )
588-
inst(INTERPRETER_EXIT) {
587+
inst(INTERPRETER_EXIT, (retval --)) {
589588
assert(frame == &entry_frame);
590589
assert(_PyFrame_IsIncomplete(frame));
591-
PyObject *retval = POP();
590+
STACK_SHRINK(1); // Since we're not going to DISPATCH()
592591
assert(EMPTY());
593592
/* Restore previous cframe and return. */
594593
tstate->cframe = cframe.previous;

Python/generated_cases.c.h

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)