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

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

Re: Numbered regexps throw invalid regex error


From: Tim Landscheidt
Subject: Re: Numbered regexps throw invalid regex error
Date: Thu, 26 Jan 2012 11:52:45 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux)

Tom <adatgyujto@gmail.com> wrote:

>> > There is no mention of an automatic assignment. It says the last one
>> > will win, so assigning a number which is already used for
>> > a previous group should work.

>> would consider it a bug then - at least a docu bug

> I don't think it's a doc bug. The whole point of the feature is that
> you can assign constant numbers to groups, so they don't change if you
> add/remove parens.

> If it can suddenly throw a regexp error, just because you've added
> a paren around an other paren then it pretty much defeats the
> prupose of the feature.

I'd agree that the documentation should be more verbose, but
I don't think that your argument that it'd be a bug is va-
lid.  If someone added another pair of parentheses around
"a\\(?1:b\\)", either they don't want to refer to it, thus
using "\\(?:", or if they want to refer to it, they have to
think about how to do that anyhow.

  How would you rephrase the documentation so that the cur-
rent behaviour is more comprehensibly described?

Tim




reply via email to

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