summaryrefslogtreecommitdiffstats
path: root/Doc/c-api
diff options
context:
space:
mode:
authorInada Naoki <songofacandy@gmail.com>2023-04-27 05:53:11 (GMT)
committerGitHub <noreply@github.com>2023-04-27 05:53:11 (GMT)
commitce2383ec6665850a1bdffad388876481b6f3205f (patch)
tree596e54fdb8b4269554623bba3d6e92bb7dd07050 /Doc/c-api
parent1d99e9e46e9b517532fea11befe2e6d0043850bd (diff)
downloadcpython-ce2383ec6665850a1bdffad388876481b6f3205f.zip
cpython-ce2383ec6665850a1bdffad388876481b6f3205f.tar.gz
cpython-ce2383ec6665850a1bdffad388876481b6f3205f.tar.bz2
gh-103883: Doc: Move PyUnicode_FromObject doc (#103913)
This API is one of Unicode creator APIs.
Diffstat (limited to 'Doc/c-api')
-rw-r--r--Doc/c-api/unicode.rst18
1 files changed, 9 insertions, 9 deletions
diff --git a/Doc/c-api/unicode.rst b/Doc/c-api/unicode.rst
index f062f14..ab3a2e2 100644
--- a/Doc/c-api/unicode.rst
+++ b/Doc/c-api/unicode.rst
@@ -509,6 +509,15 @@ APIs:
arguments.
+.. c:function:: PyObject* PyUnicode_FromObject(PyObject *obj)
+
+ Copy an instance of a Unicode subtype to a new true Unicode object if
+ necessary. If *obj* is already a true Unicode object (not a subtype),
+ return the reference with incremented refcount.
+
+ Objects other than Unicode or its subtypes will cause a :exc:`TypeError`.
+
+
.. c:function:: PyObject* PyUnicode_FromEncodedObject(PyObject *obj, \
const char *encoding, const char *errors)
@@ -616,15 +625,6 @@ APIs:
.. versionadded:: 3.3
-.. c:function:: PyObject* PyUnicode_FromObject(PyObject *obj)
-
- Copy an instance of a Unicode subtype to a new true Unicode object if
- necessary. If *obj* is already a true Unicode object (not a subtype),
- return the reference with incremented refcount.
-
- Objects other than Unicode or its subtypes will cause a :exc:`TypeError`.
-
-
Locale Encoding
"""""""""""""""