On 26 February 2014 13:57, Stephen J. Turnbull <stephen at xemacs.org> wrote: > Nick Coghlan writes that b'%a' is > > > the obvious way to interpolate representations of arbitrary objects > > into binary formats that contain ASCII compatible segments. > > The only argument that I have sympathy for is > > > %a *should* be allowed for consistency with text interpolation > > although introduction of a new format character is a poor man's > consistency, and this is consistency for consistency's sake. (I don't > have a big problem with that, though. I *like* consistency!) It's *not* a new format character, unless you mean "new in Python 3". Python 3 text interpolation has included %a for as long as I can recall, specifically as a way of spelling the old Python 2 %r interpolation behaviour now that the Python 3 %r allows Unicode text. Cheers, Nick. -- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4