GNU bug report logs - #74861
31.0.50; etags no longer processing shy groups as expected in --regex options

Previous Next

Package: emacs;

Reported by: dvilleneuve.4142 <at> gmail.com

Date: Fri, 13 Dec 2024 23:09:02 UTC

Severity: normal

Found in version 31.0.50

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Eli Zaretskii <eliz <at> gnu.org>, dvilleneuve.4142 <at> gmail.com
Cc: 74861 <at> debbugs.gnu.org
Subject: bug#74861: 31.0.50; etags no longer processing shy groups as expected in --regex options
Date: Sat, 14 Dec 2024 11:39:54 -0700
On 12/14/24 01:33, Eli Zaretskii wrote:
> I'm guessing this is because Emacs 27 switched to the Gnulib's regex
> implementation in etags and other lib-src programs, whereas previous
> versions used the Emacs's own regex code (which is still used for
> Emacs's own regex search and replacement code).
> 
> CC'ing Paul Eggert, in the hope he can tell whether this is expected
> or not, or how to fix it.

Yes that's expected, as glibc/Gnulib regex doesn't do shy groups. A 
workaround is to not use shy groups, e.g.:

etags --regex='/DEFINE_FF *(\(TAG \)? *\([^)]+\)/\2/' \
  --output ETAGS-test foo.c

This should be portable between both older and newer etags.




This bug report was last modified 205 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.