[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: regexp/emacs selective replace
From: |
Joost Kremers |
Subject: |
Re: regexp/emacs selective replace |
Date: |
25 Nov 2009 12:44:25 GMT |
User-agent: |
slrn/0.9.9p1 (Linux) |
harven wrote:
> Joost Kremers <joostkremers@yahoo.com> writes:
>
>> note that {[^}]*} could also have been written as {.*?} (which IHMO is a bit
>> clearer and easier to read).
>
> strictly speaking {[^}]*} is not the same as {.*?}
when it comes to regexps, all that counts is "strictly speaking". ;-)
> The first will match
>
> {xxx
> }
>
> because emacs regexp [^...] matches newline if it is not included in the
> brackets.
yup, true. forgot about that...
--
Joost Kremers joostkremers@yahoo.com
Selbst in die Unterwelt dringt durch Spalten Licht
EN:SiS(9)
Re: regexp/emacs selective replace, Xah Lee, 2009/11/27