what is wrong with that r"\"

Marc 'BlackJack' Rintsch bj_666 at gmx.net
Wed Jul 4 07:27:46 EDT 2007


On Wed, 04 Jul 2007 11:21:14 +0000, Neil Cerutti wrote:

> If the escaped quotes didn't function in raw strings, I'd be
> unable to construct (with a single notation) a regex that
> included both kinds of quotes at once.
> 
>   re.compile(r"'\"")

Where's the problem!? ::

  re.compile(r''''"''')

Ah, I see -- readability is the problem.  :-)

Ciao,
	Marc 'BlackJack' Rintsch



More information about the Python-list mailing list