On 2/24/2014 10:40 AM, Ethan Furman wrote:
Somebody might, and it's better than having them inappropriately add a __bytes__ method if we don't have it.
I'll admit my first thought on reading the initial discussions about adding bytes % formatting was "Oh, if I want to display custom objects in a byte stream, just add a __bytes__ method."
I don't believe there is any verbiage in the PEP (that might get transferred to the documentation) that explains why that would be a bad idea. Should there be? Whether or not %a is implemented sooner or later?
_______________________________________________ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com