Skip to content

Commit 8d9d3e4

Browse files
koyuki7wStanFromIrelandZeroIntensity
authored
gh-46236: Document PyUnicode_DecodeCodePageStateful (GH-127934)
Co-authored-by: Stan Ulbrych <[email protected]> Co-authored-by: Peter Bierma <[email protected]>
1 parent d7672e5 commit 8d9d3e4

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

Doc/c-api/unicode.rst

+7
Original file line numberDiff line numberDiff line change
@@ -1352,6 +1352,13 @@ the user settings on the machine running the codec.
13521352
in *consumed*.
13531353
13541354
1355+
.. c:function:: PyObject* PyUnicode_DecodeCodePageStateful(int code_page, const char *str, \
1356+
Py_ssize_t size, const char *errors, Py_ssize_t *consumed)
1357+
1358+
Similar to :c:func:`PyUnicode_DecodeMBCSStateful`, except uses the code page
1359+
specified by *code_page*.
1360+
1361+
13551362
.. c:function:: PyObject* PyUnicode_AsMBCSString(PyObject *unicode)
13561363
13571364
Encode a Unicode object using MBCS and return the result as Python bytes

Doc/data/refcounts.dat

+7
Original file line numberDiff line numberDiff line change
@@ -2636,6 +2636,13 @@ PyUnicode_DecodeMBCSStateful:Py_ssize_t:size::
26362636
PyUnicode_DecodeMBCSStateful:const char*:errors::
26372637
PyUnicode_DecodeMBCSStateful:Py_ssize_t*:consumed::
26382638

2639+
PyUnicode_DecodeCodePageStateful:PyObject*::+1:
2640+
PyUnicode_DecodeCodePageStateful:int:code_page::
2641+
PyUnicode_DecodeCodePageStateful:const char*:s::
2642+
PyUnicode_DecodeCodePageStateful:Py_ssize_t:size::
2643+
PyUnicode_DecodeCodePageStateful:const char*:errors::
2644+
PyUnicode_DecodeCodePageStateful:Py_ssize_t*:consumed::
2645+
26392646
PyUnicode_EncodeCodePage:PyObject*::+1:
26402647
PyUnicode_EncodeCodePage:int:code_page::
26412648
PyUnicode_EncodeCodePage:PyObject*:unicode:0:

0 commit comments

Comments
 (0)