"Steven D'Aprano" <steve+comp.lang.pyt...@pearwood.info> wrote in message news:53c66ba8$0$9505$c3e8da3$54964...@news.astraweb.com... > > E.g. having b"abc"[0] return 97 instead of b"a" was probably a mistake, > but there are four versions of Python 3.x that do it that way and it's > too late to change until Python 5000. (Python 4 is unlikely to break > backwards compatibility in a big way.) >
If it was considered important enough, couldn't they just introduce a new datatype, say B'...', with the desired behaviour. B'' would be backported to Python 2.7 as an alternative to b'', to faciliate writing code that works on both versions. There would be a lot of overlap with b'...', but the differences could be documented. Methods could be added to B'' to replicate any behaviour of b'' which has been changed. Then over time b'' could be deprecated, and in Python 4 b'' could replace B''. Frank Millman -- https://mail.python.org/mailman/listinfo/python-list