Skip to content

Commit 32d194a

Browse files
Factor out struct _ceval_interpreter_state.
1 parent 5bd5c80 commit 32d194a

File tree

2 files changed

+8
-6
lines changed

2 files changed

+8
-6
lines changed

Include/internal/pycore_ceval.h

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,13 @@ struct _pending_calls {
3434
int last;
3535
};
3636

37+
struct _ceval_interpreter_state {
38+
/* This single variable consolidates all requests to break out of
39+
the fast path in the eval loop. */
40+
_Py_atomic_int eval_breaker;
41+
struct _pending_calls pending;
42+
};
43+
3744
#include "pycore_gil.h"
3845

3946
struct _ceval_runtime_state {

Include/internal/pycore_pystate.h

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -82,12 +82,7 @@ struct _is {
8282

8383
uint64_t tstate_next_unique_id;
8484

85-
struct _ceval {
86-
/* This single variable consolidates all requests to break out of
87-
the fast path in the eval loop. */
88-
_Py_atomic_int eval_breaker;
89-
struct _pending_calls pending;
90-
} ceval;
85+
struct _ceval_interpreter_state ceval;
9186
};
9287

9388
PyAPI_FUNC(struct _is*) _PyInterpreterState_LookUpID(PY_INT64_T);

0 commit comments

Comments
 (0)