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

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

Problem with re-search-backward and "\\="


From: Alan Mackenzie
Subject: Problem with re-search-backward and "\\="
Date: Tue, 16 Sep 2003 16:44:29 +0000
User-agent: tin/1.4.5-20010409 ("One More Nightmare") (UNIX) (Linux/2.0.35 (i686))

GNU Emacs 21.1

Suppose I have this in a buffer:

foo     bar

If point is immediately after foo, then (re-search-forward "\\= *")
leaves point immediately before bar, as one would expect.

However, with point immediately before bar (re-search-backward " *\\=")
fails.  I would have expected this search to have succeeded, leaving
point just after foo.

The definition of `\=' in the elisp info page "Regexp Backslash" is:

> matches the empty string, but only at point.  (This construct is not
> defined when matching against a string.)

Is this a bug, or have I misunderstood something?

-- 
Alan Mackenzie (Munich, Germany)
Email: aacm@muuc.dee; to decode, wherever there is a repeated letter
(like "aa"), remove half of them (leaving, say, "a").



reply via email to

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