David Kastrup <[email protected]> writes:

>> Yes, that's it.  Unfortunately, I use that on purpose in
>> `reftex-label-regexps' which is a customizable list of regexps which
>> gets `regexp-opt'ed and starts `reftex-everything-regexp'.  By
>> default, it has one entry matching \label{...} and one matching
>> keyval label={...} arguments.
>>
>> RefTeX relies on the first group in `reftex-everything-regexp'
>> capturing the label name (see reftex-parse.el:242).  Without the
>> explicitly numbered groups, the regex for \label{...} would be group
>> 1, but the regex for label={...} would already be two.
>>
>> I don't see an easy fix here on my side.
>
> The first non-nil matching group?

Well, reftex also relies on group 3 being the section, group 7 being a
file being input or included, group 9 being the appendix, etc.  So when
the label becomes the first non-nil group, the section becomes the third
non-nil group after the first non-nil group...

Oh, and of course you may have a document without a \label.  Then the
first non-nil group is the section rather than the label.

Bye,
Tassilo



_______________________________________________
bug-auctex mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-auctex

Reply via email to