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

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

RE: another newbie question -- auto-mode-alist regexp


From: Robert P. J. Day
Subject: RE: another newbie question -- auto-mode-alist regexp
Date: Mon, 23 Sep 2002 19:34:00 -0400 (EDT)

On Mon, 23 Sep 2002, Robert P. J. Day wrote:

> On Mon, 23 Sep 2002, Bingham, Jay wrote:
> 
> > 1. The \\ means make the next character literal.  Two are required
> > because the string is parsed before it is placed in the variable if
> > there are not two then the single \ gets stripped out and the
> > literalness is lost.  So \. becomes just . (which means match any
> > character) while \\. becomes \. (which means find a dot).
> 
> i knew that part.  what i didn't understand was the function of
> the double-escaped sinqle quote: \\'.  what does *that* represent?
> the way it's used suggests something related to end-of-string,
> but doesn't the "$" already serve that purpose?

never mind, i finally found it in the elisp info manual.
apparently, \' matches the empty string, but only at the end
of the buffer or string being matched.

so, AFAICT, it appears to serve the same purpose as a trailing
$ to match end of string.

rday





reply via email to

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