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

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

Regexps


From: Teemu Likonen
Subject: Regexps
Date: Fri, 02 Jan 2009 12:19:54 +0200
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.2 (gnu/linux)

Samuel Wales (2009-01-01 15:18 -0700) wrote:

> On Thu, Jan 1, 2009 at 07:16, Teemu Likonen <address@hidden> wrote:
>>    (add-to-list 'auto-mode-alist '("\\.org\\'" . org-mode))
>
> Maybe without the \ \ ' ?  Or is that a special thing?

The \' atom matches with zero-width at the end of string or end of
buffer. As you know $ is a zero-width atom that matches at the end of
line. In theory a filename may contain newlines (in Linux filesystems at
least) and in such situations the $ atom wouldn't necessarily match the
end of the whole filename string.




reply via email to

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