Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

query-replace inside the processed region selects the first match, rather than the next one #41

Closed
JasonGross opened this issue Jan 25, 2016 · 3 comments

Comments

@JasonGross
Copy link
Contributor

If I use query-replace, and press RET to replace a match inside the processed region, the processed region (correctly) reverts, but then the next match selected is the first match of the document, rather than the subsequent match in the sequence.

@hendriktews
Copy link
Collaborator

hendriktews commented Jan 25, 2016 via email

@Matafou
Copy link
Contributor

Matafou commented Jan 25, 2016

Strange bug. Retraction seems correctly protected against that. Strangely
enough it does not seem to got exactly to the top of the buffer (misses
first lines).

Looks like a specific bad interaction with query-replace.

P.

2016-01-25 11:59 GMT+01:00 hendriktews notifications@github.com:

This sounds like retraction is moving point around. We should
eventually fix this.

H.


Reply to this email directly or view it on GitHub
#41 (comment).

@erikmd
Copy link
Member

erikmd commented Sep 24, 2016

Hello,
I've just looked at this issue, and found that enclosing the end of function proof-retract-before-change in a (save-match-data &rest BODY) successfully protects retraction with respect to query-replace and replace-string. So I'm going to push my patch and close the issue.
Best regards, EMD

@erikmd erikmd closed this as completed in 71be0c6 Sep 24, 2016
tchajed pushed a commit to tchajed/PG that referenced this issue Oct 14, 2016
erikmd added a commit that referenced this issue Oct 15, 2016
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants