GNU bug report logs - #25562
25.1; isearch-forward-word first matches a non-word

Previous Next

Package: emacs;

Reported by: Antoine Levitt <antoine.levitt <at> gmail.com>

Date: Sat, 28 Jan 2017 11:24:02 UTC

Severity: minor

Merged with 22589

Found in versions 25.0.90, 25.1

Done: Juri Linkov <juri <at> linkov.net>

Bug is archived. No further changes may be made.

Full log


Message #40 received at 25562 <at> debbugs.gnu.org (full text, mbox):

From: Juri Linkov <juri <at> linkov.net>
To: Michael Heerdegen <michael_heerdegen <at> web.de>
Cc: 25562 <at> debbugs.gnu.org, Antoine Levitt <antoine.levitt <at> gmail.com>
Subject: Re: bug#25562: 25.1; isearch-forward-word first matches a non-word
Date: Wed, 01 Feb 2017 02:38:16 +0200
>> merge 22589 25562
>> thanks
>
> AFAIK you didn't yet make the change so that the lax matching state is
> recognizable from the prompt.  No hurry, but I think this report shows
> that the current behavior is at first surprising to users.  Maybe even a
> stronger term than your suggested "Pending" would be appropriate.

Thanks for confirming that it would be a good solution.
We are already using "Pending" indication in the search prompt
in other places to show that the search is not yet fully accepted.
This could do the same for word search as well:

diff --git a/lisp/isearch.el b/lisp/isearch.el
index 5c48c30..3c9dff1 100644
--- a/lisp/isearch.el
+++ b/lisp/isearch.el
@@ -2741,6 +2747,8 @@ (defun isearch-search-fun-default ()
            (if isearch-forward #'re-search-forward #'re-search-backward)
            (cond (isearch-regexp-function
                   (let ((lax (isearch--lax-regexp-function-p)))
+                    (when lax
+                      (setq isearch-adjusted t))
                     (if (functionp isearch-regexp-function)
                         (funcall isearch-regexp-function string lax)
                       (word-search-regexp string lax))))




This bug report was last modified 8 years and 98 days ago.

Previous Next


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