[Python-Dev] 3.0 C API to decode bytes into unicode? (original) (raw)
Benjamin Peterson musiccomposition at gmail.com
Fri Aug 1 15:29:28 CEST 2008
- Previous message: [Python-Dev] 3.0 C API to decode bytes into unicode?
- Next message: [Python-Dev] 3.0 C API to decode bytes into unicode?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Fri, Aug 1, 2008 at 8:06 AM, Barry Scott <barry at barrys-emacs.org> wrote:
I cannot see how I implement decode() for bytes objects using the C API for PyCXX library,
I'd assuming that I should find a PyBytesDecode function but cannot find it in beta 2. What is the preferred way to do this?
PyObject_CallMethod(bytesobj, "decode", "")
PyUnicode_FromEncodedObject takes an encoding argument.
Barry
Python-Dev mailing list Python-Dev at python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/musiccomposition%40gmail.com
-- Cheers, Benjamin Peterson "There's no place like 127.0.0.1."
- Previous message: [Python-Dev] 3.0 C API to decode bytes into unicode?
- Next message: [Python-Dev] 3.0 C API to decode bytes into unicode?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]