[Python-Dev] Allowing u.encode() to return non-strings

"Martin v. Löwis" martin at v.loewis.de
Sat Jun 26 06:04:20 EDT 2004


Bill Janssen wrote:
> While we're talking about this, Martin, what is the encoding of the
> "string" returned by
> 
>       struct.pack("bbb", 0xFF, 0x00, 0x83)
> 
> And what should it be?

It's a byte string, so it doesn't have an encoding. It's MIME
type might be 'application/octet-stream'.

Regards,
Martin




More information about the Python-Dev mailing list