[Python-Dev] PEP 461 - Adding % and {} formatting to bytes

Greg Ewing greg.ewing at canterbury.ac.nz
Wed Jan 15 22:55:31 CET 2014

Neil Schemenauer wrote:
> Objects that implement __str__ can also implement __bytes__ if they
> can guarantee that ASCII characters are always returned,

I think __ascii_ would be a better name. I'd expect
a method called __bytes__ on an int to return some
version of its binary value.


More information about the Python-Dev mailing list