On 03/27/2014 11:53 AM, Guido van Rossum wrote: > > So what's the use case for Python 2/3 compatible code? IMO the main use case for the PEP is simply to be able to > construct bytes from a combination of a template and some input that may include further bytes and numbers. E.g. in > asyncio when you write an HTTP client or server you have to construct bytes to write to the socket, and I'd be happy if > I could write b'HTTP/1.0 %d %b\r\n' % (status, message) rather than having to use str(status).encode('ascii') and > concatenation or join(). My own dbf module [1] would make use of this feature, and I'm sure some of the pdf modules would as well (I recall somebody chiming in about their own pdf module). -- ~Ethan~ [1] https://pypi.python.org/pypi/dbf
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