GNU bug report logs - #14013
24.3.50; dired-isearch-filenames-regexp is matching text outside filenames

Previous Next

Package: emacs;

Reported by: michael_heerdegen <at> web.de

Date: Wed, 20 Mar 2013 23:42:01 UTC

Severity: normal

Tags: patch

Merged with 29215

Found in versions 24.3.50, 26.0

Fixed in version 29.0.50

Done: Juri Linkov <juri <at> jurta.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Michael Heerdegen <michael_heerdegen <at> web.de>
To: 14013 <at> debbugs.gnu.org
Cc: juri <at> jurta.org, monnier <at> iro.umontreal.ca
Subject: bug#14013: 24.3.50; dired-isearch-filenames-regexp is matching text outside filenames
Date: Wed, 16 Feb 2022 02:11:10 +0100
Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of
text editors" <bug-gnu-emacs <at> gnu.org> writes:

> I don't know if we want to handle ^ specially, but if we do we can use
> something like:
>
>     (while (string-match "\\^" RE i)
>       (setq i (match-end 0))
>       (if (not (subregexp-context-p RE (match-beginning 0)))
>           ;; The ^ is inside a char-range or escaped or something.
>           nil
>         (setq RE (replace-match (concat "\\(?:"
>                                         directory-listing-before-filename-regexp
>                                         "\\)")
>                                 t t RE))))

Will matches then not be discarded by `dired-isearch-filenames-mode'
because they start before the file name?

Michael.




This bug report was last modified 1 year and 352 days ago.

Previous Next


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