unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Juri Linkov <juri@linkov.net>
To: Augusto Stoffel <arstoffel@gmail.com>
Cc: 46469@debbugs.gnu.org
Subject: bug#46469: 27.1; `isearch-del-char' should move point further back
Date: Wed, 28 Apr 2021 23:53:14 +0300	[thread overview]
Message-ID: <87r1iu6shx.fsf@mail.linkov.net> (raw)
In-Reply-To: <875z074lf3.fsf@gmail.com> (Augusto Stoffel's message of "Tue, 27 Apr 2021 20:44:32 +0200")

> For the record, the search ring advance/retreat commands suffer from a
> bug similar to the `isearch-del-char' one described here.
>
> Namely, `C-s M-p M-p M-p' presumably takes you to the first match, after
> the starting point, of the third history element.  It would be very
> strange to expect that the result of this key sequence depends on the
> first and second history elements, or on the contents of the buffer
> beyond the first match of the third history element.
>
> And, in fact, everything is fine when `search-ring-update' is nil.
> However:
>
> (progn
>   (setq search-ring-update t

Your proposed change makes sense.  Since this is a non-default value
of search-ring-update, I'm not sure how the users who customized it to t
would like such change.

>> I tried again, but your patch still doesn't work.  With
>> It signals the error "Keyboard macro terminated by a command ringing the bell".
>
> Now I see, my old patch only worked in regexp mode (which is `C-s' for
> me).  The attached one seems to work (but this is subtle stuff, there
> may be edge cases).

Thanks, now it's clear why it didn't work when I tried.

But this change will cause a problem to me.  Usually, I type 'C-s'
several times with a non-empty search string to arrive to Nth occurrence.
Then to be able to continue the search with a shorter string, I remove
some characters from the search string with 'C-M-d' (isearch-del-char).
Then continue searching with 'C-s' from the same place.  But with the patch,
'C-M-d' unexpectedly jumps to a previous match, and every next 'C-M-d'
jumps back it its previous match that makes no sense.





  reply	other threads:[~2021-04-28 20:53 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-12 18:56 bug#46469: 27.1; `isearch-del-char' should move point further back Augusto Stoffel
2021-02-12 20:00 ` Eli Zaretskii
2021-02-12 20:20   ` Augusto Stoffel
2021-02-13  7:04     ` Eli Zaretskii
2021-02-13  7:32       ` Augusto Stoffel
2021-02-13  8:59         ` Eli Zaretskii
2021-02-13  9:53           ` Augusto Stoffel
2021-02-13 13:28             ` Eli Zaretskii
2021-02-13 23:14           ` bug#46469: [External] : " Drew Adams
2021-02-14  3:42             ` Eli Zaretskii
2021-02-14  7:18               ` Augusto Stoffel
2021-02-14 15:24                 ` Eli Zaretskii
2021-02-14 17:49                 ` Juri Linkov
2021-02-15 19:31                   ` Augusto Stoffel
2021-02-15 19:41                     ` Eli Zaretskii
2021-02-13 18:31 ` Juri Linkov
2021-02-14  7:00   ` Augusto Stoffel
2021-02-14 17:45     ` Juri Linkov
2021-04-27 18:44       ` Augusto Stoffel
2021-04-28 20:53         ` Juri Linkov [this message]
2021-04-28 21:16           ` Augusto Stoffel
2021-04-28 21:37             ` Juri Linkov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87r1iu6shx.fsf@mail.linkov.net \
    --to=juri@linkov.net \
    --cc=46469@debbugs.gnu.org \
    --cc=arstoffel@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).