Skip to content

Commit

Permalink
gh-127787: Move _PyUnicodeError_GetParams() to the internal C API (#1…
Browse files Browse the repository at this point in the history
  • Loading branch information
vstinner authored Jan 14, 2025
1 parent eefd4a0 commit 24a8d92
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
6 changes: 0 additions & 6 deletions Include/cpython/pyerrors.h
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,6 @@ PyAPI_FUNC(void) _PyErr_ChainExceptions1(PyObject *);

/* In exceptions.c */

PyAPI_FUNC(int) _PyUnicodeError_GetParams(
PyObject *self,
PyObject **obj, Py_ssize_t *objlen,
Py_ssize_t *start, Py_ssize_t *end,
int as_bytes);

PyAPI_FUNC(PyObject*) PyUnstable_Exc_PrepReraiseStar(
PyObject *orig,
PyObject *excs);
Expand Down
9 changes: 9 additions & 0 deletions Include/internal/pycore_pyerrors.h
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,15 @@ Py_DEPRECATED(3.12) extern void _PyErr_ChainExceptions(PyObject *, PyObject *, P
PyAPI_DATA(PyTypeObject) _PyExc_IncompleteInputError;
#define PyExc_IncompleteInputError ((PyObject *)(&_PyExc_IncompleteInputError))

extern int _PyUnicodeError_GetParams(
PyObject *self,
PyObject **obj,
Py_ssize_t *objlen,
Py_ssize_t *start,
Py_ssize_t *end,
int as_bytes);


#ifdef __cplusplus
}
#endif
Expand Down

0 comments on commit 24a8d92

Please sign in to comment.