what is wrong with that r"\"
Neil Cerutti
horpner at yahoo.com
Wed Jul 4 12:41:11 EDT 2007
On 2007-07-04, Neil Cerutti <horpner at yahoo.com> wrote:
> On 2007-07-04, Marc 'BlackJack' Rintsch <bj_666 at gmx.net> wrote:
>> 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''''"''')
>
> That incurs the problem that you can't end with a '. So you
> can't end with *something* either way.
I take that back. With good planning, you can end with whichever
you need by choosing the other delimiter.
Oh well. It seemed like a good explanation at first.
--
Neil Cerutti
More information about the Python-list
mailing list