help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to grep for a string spanning multiple lines?


From: Jean Louis
Subject: Re: How to grep for a string spanning multiple lines?
Date: Sun, 27 Nov 2022 10:44:44 +0300
User-agent: Mutt/2.2.7+37 (a90f69b) (2022-09-02)

* Michael Heerdegen <michael_heerdegen@web.de> [2022-11-27 10:32]:
> Jean Louis <bugs@gnu.support> writes:
> 
> > It means it is not to be used to search for new lines in program, as
> > programs may not have syntax tables.
> >
> > Then this is solution:
> >
> > (rx (one-or-more (or "\n" (any whitespace)))) ➜ "\\(?:
> > \\|[[:space:]]\\)+"
> 
> `rx' has a keyword to mach any char (including whitespace), it's
> called `anychar'.

OK sure, thanks. Though I can't see relation from any char to
searching for whitespaces including new line. How do you mean it?

-- 
Jean

Take action in Free Software Foundation campaigns:
https://www.fsf.org/campaigns

In support of Richard M. Stallman
https://stallmansupport.org/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]