emacs-devel
[Top][All Lists]
Advanced

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

Re: Structural regular expressions


From: Tom
Subject: Re: Structural regular expressions
Date: Thu, 9 Sep 2010 16:53:10 +0000 (UTC)
User-agent: Loom/3.14 (http://gmane.org/)

Lennart Borgman <lennart.borgman <at> gmail.com> writes:

> > And what happens then if I want to regexp replace "foo\s-*bar"? It would
> > still be susceptible to the above mentioned boundary problem, so it's
> > not a robust workaround.
> 
> It does not look to me like it would be susceptible to that problem.
> Maybe I am misunderstanding you. Can you explain more in detail why
> you think it would be a problem with the solution I suggested? (Please
> note that I said the parts outside of the multiple narrowing should be
> treated as "whitespace", not "invisible" or "non-existent".)

Maybe I am misunderstanding you.

As I understood your suggestion:

<.....foo> ... whitespace ... <bar ... >

Since \s- as a regexp matches whitespace the regexp "foo\s-*bar" would match 
the end of the first range and the beginning of the second range separated
by whitespace.




reply via email to

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