X Tutup
Skip to content

[3.6] bpo-30708: Add private C API function _PyUnicode_AsWideCharString(). (GH-2285)#2443

Merged
serhiy-storchaka merged 1 commit intopython:3.6from
serhiy-storchaka:backport-e613e6a-3.6
Jun 27, 2017
Merged

[3.6] bpo-30708: Add private C API function _PyUnicode_AsWideCharString(). (GH-2285)#2443
serhiy-storchaka merged 1 commit intopython:3.6from
serhiy-storchaka:backport-e613e6a-3.6

Conversation

@serhiy-storchaka
Copy link
Copy Markdown
Member

And use it instead of PyUnicode_AsWideCharString() if appropriate.

_PyUnicode_AsWideCharString(unicode) is like PyUnicode_AsWideCharString(unicode, NULL), but
raises a ValueError if the wchar_t* string contains null characters.
(cherry picked from commit e613e6a)

…ing(). (pythonGH-2285)

Raise a ValueError if the second argument is NULL and the wchar_t\*
string contains null characters..
(cherry picked from commit e613e6a)
@serhiy-storchaka serhiy-storchaka added needs backport to 3.5 type-bug An unexpected behavior, bug, or error labels Jun 27, 2017
@serhiy-storchaka serhiy-storchaka merged commit 0edffa3 into python:3.6 Jun 27, 2017
@serhiy-storchaka serhiy-storchaka deleted the backport-e613e6a-3.6 branch June 27, 2017 18:09
serhiy-storchaka added a commit to serhiy-storchaka/cpython that referenced this pull request Jun 27, 2017
…harString(). (pythonGH-2285) (pythonGH-2443)

Raise a ValueError if the second argument is NULL and the wchar_t\*
string contains null characters..
(cherry picked from commit e613e6a).
(cherry picked from commit 0edffa3)
serhiy-storchaka added a commit that referenced this pull request Jun 27, 2017
…ng(). (GH-2285) (GH-2443)  (#2448)

And use it instead of PyUnicode_AsWideCharString() if appropriate.

_PyUnicode_AsWideCharString(unicode) is like PyUnicode_AsWideCharString(unicode, NULL), but
raises a ValueError if the wchar_t* string contains null characters.
(cherry picked from commit e613e6a).
(cherry picked from commit 0edffa3)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type-bug An unexpected behavior, bug, or error

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

X Tutup