escaping/encoding/formatting in python

Nobody nobody at nowhere.com
Fri Apr 6 04:52:57 EDT 2012


On Thu, 05 Apr 2012 22:28:19 -0700, rusi wrote:

> All this mess would vanish if the string-literal-starter and ender
> were different.

You still need an escape character in order to be able to embed an
unbalanced end character.

Tcl and PostScript use mirrored string delimiters (braces for Tcl,
parentheses for PostScript), which results in the worst of both worlds:
they still need an escape character (backslash, in both cases) but now you
can't match tokens with a regexp/DFA.




More information about the Python-list mailing list