[Python-3000] Displaying strings containing unicode escapes
Oleg Broytmann
phd at phd.pp.ru
Thu May 1 19:56:32 CEST 2008
On Thu, May 01, 2008 at 01:49:37PM -0400, Terry Reedy wrote:
> I think standard Python should somehow have two options: escape everything
> but ASCII (for unambuguity and old display systems) and escape nothing that
> is potentially printable (leaving partially capable systems to fare as they
> will). In-between solutions will ultimately be programmer and system
> specific.
+1
repr() should not escape printable chars, and there should be a codec to
escape everything, so one could write mystring.encode("escape_string").
Oleg.
--
Oleg Broytmann http://phd.pp.ru/ phd at phd.pp.ru
Programmers don't die, they just GOSUB without RETURN.
More information about the Python-3000
mailing list