[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-
From: |
Juri Linkov |
Subject: |
bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results |
Date: |
Sun, 08 May 2016 23:19:07 +0300 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.0.93 (x86_64-pc-linux-gnu) |
> 1. Do a search that has several matches in one buffer, e.g. using
> dired-do-find-regexp.
> 2. Press `r' in the *xref* buffer, to initiate replacement. Input `.*'
> and `abcd', for instance. This value of FROM is important.
> 3. Replace a couple then undo that (press y, y, u, u).
> 4. Try agreeing with the subsequent prompts. The replacements performed
> then will be wrong.
>
> I've tried to come up with a patch but stopped short of really delving
> into the code of perform-replace. Which seems really necessary at this
> point. Attaching what I already have.
I can't reproduce this when using normal query-replace.
Is this caused by binding local variables in xref--query-replace-1?
Then maybe there is a better way to achieve the same.
> The big problem is that perform-replace does not consistently use
> replace-re-search-function. With the new undo code, it's became worse.
> After you press `u', it seems to switch to moving around the saved match
> data stack and using a plain looking-at, without checking with
> isearch-filter-predicate.
You don't need isearch-filter-predicate when doing undo
because a previous replacement already checked it, no?
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results, Dmitry Gutov, 2016/05/08
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results,
Juri Linkov <=
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results, Dmitry Gutov, 2016/05/08
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results, Juri Linkov, 2016/05/09
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results, Dmitry Gutov, 2016/05/09
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results, Dmitry Gutov, 2016/05/09
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results, Juri Linkov, 2016/05/10
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results, Dmitry Gutov, 2016/05/10
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results, Juri Linkov, 2016/05/11
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results, Dmitry Gutov, 2016/05/11
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results, Juri Linkov, 2016/05/12
- bug#23484: 25.1.50; undo doesn't work properly in xref-query-replace-in-results, Dmitry Gutov, 2016/05/12