[Python-ideas] bitwise operations on bytes
ede at mit.edu
Fri Aug 7 15:31:27 CEST 2009
> One other question: if a has type bytes and b has type bytearray,
> what types would you propose that a & b and b & a should have?
For consistency they should probably do what they currently do with
concatenation: the type of the first expression is the type of the
>>> b'a' + bytearray(b'b')
>>> bytearray(b'b') + b'a'
More information about the Python-ideas