Bengt Richter wrote: > On Sat, 18 Feb 2006 09:59:38 +0100, > =?ISO-8859-1?Q?=22Martin_v=2E_L=F6wis=22?= <[EMAIL PROTECTED]> wrote:
> Thinking about bytes recently, it occurs to me that bytes are really not > intrinsically > numeric in nature. They don't necessarily represent uint8's. E.g., a binary > file is > really a sequence of bit octets in its most primitive and abstract sense. In that you would want to do different types of operations on single byte (an octet) than you would on str, or integer, I agree. Storing byte information as 16 or 32 bits ints could take up a rather lot of memory in some cases. I don't think it's been clarified yet weather the bytes() type would be implemented in C where it could be a single object with access to it's individual bytes via indexing, or python list type object which stores integers, chars or some other byte length object like octets. My first impression is that it would be done in C with a way to access and change the actual bytes. So a Python octet type wouldn't be needed. But if it is implemented as a Python subclass of list or array, then an octet type would probably also be desired. > Bottom line thought: binary octets aren't numeric ;-) +1 Cheers, Ronald Adam _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com