mirror of
https://github.com/python/cpython.git
synced 2026-01-31 11:42:19 +00:00
gh-128863: Deprecate private C API functions (#128864)
Deprecate private C API functions: * _PyBytes_Join() * _PyDict_GetItemStringWithError() * _PyDict_Pop() * _PyThreadState_UncheckedGet() * _PyUnicode_AsString() * _Py_HashPointer() * _Py_fopen_obj() Replace _Py_HashPointer() with Py_HashPointer(). Remove references to deprecated functions.
This commit is contained in:
parent
470a0a68eb
commit
9012fa741d
16 changed files with 103 additions and 30 deletions
|
|
@ -630,8 +630,12 @@ _PyUnicodeWriter_Dealloc(_PyUnicodeWriter *writer);
|
|||
|
||||
PyAPI_FUNC(const char *) PyUnicode_AsUTF8(PyObject *unicode);
|
||||
|
||||
// Alias kept for backward compatibility
|
||||
#define _PyUnicode_AsString PyUnicode_AsUTF8
|
||||
// Deprecated alias kept for backward compatibility
|
||||
Py_DEPRECATED(3.14) static inline const char*
|
||||
_PyUnicode_AsString(PyObject *unicode)
|
||||
{
|
||||
return PyUnicode_AsUTF8(unicode);
|
||||
}
|
||||
|
||||
|
||||
/* === Characters Type APIs =============================================== */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue