[issue2799] Remove PyUnicode_AsString(), rework PyUnicode_AsStringAndSize(), add PyUnicode_AsChar()
Stefan Behnel
report at bugs.python.org
Fri Jun 6 10:38:10 CEST 2008
Stefan Behnel <scoder at users.sourceforge.net> added the comment:
While PyUnicode_AsStringAndSize() may be a better solution if the length
is required, PyUnicode_AsString is enough() when it is not required. So
I don't buy that argument. Since there are dedicated UTF-8 encoding
functions, both functions are pure convenience anyway.
Embedded \0 bytes can bite you, but that's completely unrelated to the
issue discussed here.
I wouldn't oppose renaming the function, but I don't see why it should go.
----------
nosy: +scoder
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue2799>
_______________________________________
More information about the Python-bugs-list
mailing list