Skip to content

Commit e2fef0c

Browse files
committed
Yeah can't internalize foreach macro
1 parent 59df955 commit e2fef0c

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

Include/cpython/context.h

+4
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ PyAPI_FUNC(PyObject *) PyContext_CopyCurrent(void);
2727
PyAPI_FUNC(int) PyContext_Enter(PyObject *);
2828
PyAPI_FUNC(int) PyContext_Exit(PyObject *);
2929

30+
#define Py_FOREACH_CONTEXT_EVENT(V) \
31+
V(ENTER) \
32+
V(EXIT)
33+
3034
typedef enum {
3135
#define Py_DEF_EVENT(op) Py_CONTEXT_EVENT_##op,
3236
Py_FOREACH_CONTEXT_EVENT(Py_DEF_EVENT)

Include/internal/pycore_context.h

-3
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,6 @@ struct _pycontexttokenobject {
5151
int tok_used;
5252
};
5353

54-
#define Py_FOREACH_CONTEXT_EVENT(V) \
55-
V(ENTER) \
56-
V(EXIT)
5754

5855
// _testinternalcapi.hamt() used by tests.
5956
// Export for '_testcapi' shared extension

0 commit comments

Comments
 (0)