[Python-Dev] PEP 460: allowing %d and %f and mojibake (original) (raw)
Georg Brandl g.brandl at gmx.net
Sun Jan 12 10:23:54 CET 2014
- Previous message: [Python-Dev] PEP 460: allowing %d and %f and mojibake
- Next message: [Python-Dev] PEP 460: allowing %d and %f and mojibake
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Am 12.01.2014 09:57, schrieb Paul Moore:
On 12 January 2014 01:01, Victor Stinner <victor.stinner at gmail.com> wrote:
Supporting formating integers would allow to write b"Content-Length: %s\r\n" % 123, which would work on Python 2 and Python 3. I'm surprised that no-one is mentioning b"Content-Length: %s\r\n" % str(123) which works on Python 2 and 3, is explicit, and needs no special-casing of int in the format code.
Certainly doesn't work on Python 3 right now, and never should :)
Georg
- Previous message: [Python-Dev] PEP 460: allowing %d and %f and mojibake
- Next message: [Python-Dev] PEP 460: allowing %d and %f and mojibake
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]