mirror of
https://github.com/python/cpython.git
synced 2025-11-01 02:38:53 +00:00
bpo-41123: Remove PyUnicode_AsUnicodeCopy (GH-21209)
This commit is contained in:
parent
2515a28230
commit
b3332660ad
6 changed files with 5 additions and 58 deletions
|
|
@ -724,20 +724,6 @@ Extension modules can continue using them, as they will not be removed in Python
|
|||
.. versionadded:: 3.3
|
||||
|
||||
|
||||
.. c:function:: Py_UNICODE* PyUnicode_AsUnicodeCopy(PyObject *unicode)
|
||||
|
||||
Create a copy of a Unicode string ending with a null code point. Return ``NULL``
|
||||
and raise a :exc:`MemoryError` exception on memory allocation failure,
|
||||
otherwise return a new allocated buffer (use :c:func:`PyMem_Free` to free
|
||||
the buffer). Note that the resulting :c:type:`Py_UNICODE*` string may
|
||||
contain embedded null code points, which would cause the string to be
|
||||
truncated when used in most C functions.
|
||||
|
||||
.. versionadded:: 3.2
|
||||
|
||||
Please migrate to using :c:func:`PyUnicode_AsUCS4Copy` or similar new APIs.
|
||||
|
||||
|
||||
.. c:function:: Py_ssize_t PyUnicode_GetSize(PyObject *unicode)
|
||||
|
||||
Return the size of the deprecated :c:type:`Py_UNICODE` representation, in
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue