Issue #28769: The result of PyUnicode_AsUTF8AndSize() and PyUnicode_AsUTF8()

is now of type "const char *" rather of "char *".
This commit is contained in:
Serhiy Storchaka 2017-01-22 23:07:07 +02:00
parent d528791096
commit 2a404b63d4
9 changed files with 26 additions and 13 deletions

View file

@ -3972,7 +3972,7 @@ PyUnicode_FSDecoder(PyObject* arg, void* addr)
}
char*
const char *
PyUnicode_AsUTF8AndSize(PyObject *unicode, Py_ssize_t *psize)
{
PyObject *bytes;
@ -4007,7 +4007,7 @@ PyUnicode_AsUTF8AndSize(PyObject *unicode, Py_ssize_t *psize)
return PyUnicode_UTF8(unicode);
}
char*
const char *
PyUnicode_AsUTF8(PyObject *unicode)
{
return PyUnicode_AsUTF8AndSize(unicode, NULL);