[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: how can I make regexp expression effective across many lines
From: |
Pascal Bourguignon |
Subject: |
Re: how can I make regexp expression effective across many lines |
Date: |
Tue, 30 Jan 2007 00:05:59 +0100 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.91 (gnu/linux) |
"Drew Adams" <drew.adams@oracle.com> writes:
>> . matches any character except a newline character.
>> [^\n] matches any character.
>
> Oops. I should have said \(.\|\n\). In Lisp, that's \\(.\\|\n\\).
> Asleep at the wheel...
Not exactly. It's:
\(.\|
\)
(if you must enter it in the minibuffer for example, typing C-q C-j to
insert the newline), or the result of evaluating: "\\(.\\|\n\\)" (if
you type it in an elisp program).
--
__Pascal Bourguignon__ http://www.informatimago.com/
There is no worse tyranny than to force a man to pay for what he does not
want merely because you think it would be good for him. -- Robert Heinlein