[Top][All Lists]

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

Re: Case-sensitive support with regexp specials ?

From: Kevin Rodgers
Subject: Re: Case-sensitive support with regexp specials ?
Date: Thu, 16 Dec 2004 10:33:53 -0700
User-agent: Mozilla Thunderbird 0.9 (X11/20041105)

Sun Yijiang wrote:
> On Wed, 15 Dec 2004 09:57:49 -0500, Richard Stallman <address@hidden> wrote:
> > > It seems that Emacs only provides a method to do case insensitive
> > > search with "regexp search functions", not with "regexp specials",
> > > like vim does.
> >
> > Sorry, I don't know what that means.  I do not use vim.
> > Could you explain?
> In vim regexp, `\c' means "ignore case diffs from here" and `\C' means
> "consider case diffs from here".  Thus, `\chello\CWorld' matches
> "HeLloWorld" but does not match "helloWoRLd".  In GNU Emacs, this
> regexp should be `[hH][eE][lL][lL][oO]World', which is a little bit
> ugly and not very convenient in some cases.

Yuck: IMHO a balanced syntax like \(?:...\) would be better than a
      state-switching construction.

Cool: You could combine that with \sw to match upper- and lower-case
words in any character set, without having to enumerate the character

Kevin Rodgers

reply via email to

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