[Python-Dev] Re: adding a bytes sequence type to Python (original) (raw)
M.-A. Lemburg mal at egenix.com
Mon Aug 16 20:27:50 CEST 2004
- Previous message: [Python-Dev] Re: adding a bytes sequence type to Python
- Next message: [Python-Dev] Re: adding a bytes sequence type to Python
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Martin v. Löwis wrote:
M.-A. Lemburg wrote:
If we switch the binding of 'yyy' to mean unicode('yyy') some day, why can't we just continue to use the existing implementation for 8-bit strings for b'xxx' (the current implementation is already doing the right thing, meaning that it is 8-bit safe regardeless of the source code encoding) ? Not exactly - the current implementation is not safe with respect to re-encoding source in a different encoding.
It is if you stick to writing your binary data using an ASCII compatible encoding -- I wouldn't expect any other encoding for binary data anyway. The most common are ASCII + escape sequences, base64 or hex, all of which are ASCII compatible.
-- Marc-Andre Lemburg eGenix.com
Professional Python Services directly from the Source (#1, Aug 16 2004)
Python/Zope Consulting and Support ... http://www.egenix.com/ mxODBC.Zope.Database.Adapter ... http://zope.egenix.com/ mxODBC, mxDateTime, mxTextTools ... http://python.egenix.com/
::: Try mxODBC.Zope.DA for Windows,Linux,Solaris,FreeBSD for free ! ::::
- Previous message: [Python-Dev] Re: adding a bytes sequence type to Python
- Next message: [Python-Dev] Re: adding a bytes sequence type to Python
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]