Skip to content

Commit

Permalink
gh-106320: Remove _Py_SwappedOp from the C API
Browse files Browse the repository at this point in the history
Move _Py_SwappedOp to the internal C API (pycore_object.h).
  • Loading branch information
vstinner committed Jul 22, 2023
1 parent eda9ce1 commit 136f64d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
5 changes: 0 additions & 5 deletions Include/cpython/object.h
Original file line number Diff line number Diff line change
Expand Up @@ -377,11 +377,6 @@ PyAPI_FUNC(PyObject *) _PyObject_FunctionStr(PyObject *);
#endif


/* Maps Py_LT to Py_GT, ..., Py_GE to Py_LE.
* Defined in object.c.
*/
PyAPI_DATA(int) _Py_SwappedOp[];

PyAPI_FUNC(void)
_PyDebugAllocatorStats(FILE *out, const char *block_name, int num_blocks,
size_t sizeof_block);
Expand Down
3 changes: 3 additions & 0 deletions Include/internal/pycore_object.h
Original file line number Diff line number Diff line change
Expand Up @@ -442,6 +442,9 @@ extern PyObject* _PyCFunctionWithKeywords_TrampolineCall(
PyAPI_DATA(PyTypeObject) _PyNone_Type;
PyAPI_DATA(PyTypeObject) _PyNotImplemented_Type;

/* Maps Py_LT to Py_GT, ..., Py_GE to Py_LE. Defined in Objects/object.c. */
extern int _Py_SwappedOp[];

#ifdef __cplusplus
}
#endif
Expand Down

0 comments on commit 136f64d

Please sign in to comment.