Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 24a8d92

Browse files
authored
gh-127787: Move _PyUnicodeError_GetParams() to the internal C API (#128803)
1 parent eefd4a0 commit 24a8d92

File tree

2 files changed

+9
-6
lines changed

2 files changed

+9
-6
lines changed

Include/cpython/pyerrors.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -94,12 +94,6 @@ PyAPI_FUNC(void) _PyErr_ChainExceptions1(PyObject *);
9494

9595
/* In exceptions.c */
9696

97-
PyAPI_FUNC(int) _PyUnicodeError_GetParams(
98-
PyObject *self,
99-
PyObject **obj, Py_ssize_t *objlen,
100-
Py_ssize_t *start, Py_ssize_t *end,
101-
int as_bytes);
102-
10397
PyAPI_FUNC(PyObject*) PyUnstable_Exc_PrepReraiseStar(
10498
PyObject *orig,
10599
PyObject *excs);

Include/internal/pycore_pyerrors.h

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,15 @@ Py_DEPRECATED(3.12) extern void _PyErr_ChainExceptions(PyObject *, PyObject *, P
190190
PyAPI_DATA(PyTypeObject) _PyExc_IncompleteInputError;
191191
#define PyExc_IncompleteInputError ((PyObject *)(&_PyExc_IncompleteInputError))
192192

193+
extern int _PyUnicodeError_GetParams(
194+
PyObject *self,
195+
PyObject **obj,
196+
Py_ssize_t *objlen,
197+
Py_ssize_t *start,
198+
Py_ssize_t *end,
199+
int as_bytes);
200+
201+
193202
#ifdef __cplusplus
194203
}
195204
#endif

0 commit comments

Comments
 (0)