all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Jayden Navarro <jayden@yugabyte.com>
To: Alan Mackenzie <acm@muc.de>
Cc: 36328@debbugs.gnu.org
Subject: bug#36328: 26.2; Args out of range on search-and-replace of *.cc file
Date: Sun, 23 Jun 2019 09:14:19 -0700	[thread overview]
Message-ID: <CAEKiUEZy4scEedt=3vcP=2e-9yr6cqW4QYk98DK-ajGwf_hJrA@mail.gmail.com> (raw)
In-Reply-To: <20190623122207.GA4736@ACM>

[-- Attachment #1: Type: text/plain, Size: 1163 bytes --]

Hi Alan,

Thank you for looking into this!

Until this is officially fixed I've come up with the following workaround,
going off of the details you provided:

I created a "replace_fixed.el" file in "~/.emacs.d/lisp/" that is
replace.el taken from
https://raw.githubusercontent.com/emacs-mirror/emacs/emacs-26/lisp/replace.el
with
the following diff:

diff --git a/replace.el b/replace_fixed.el
index 08feb8e..8280fdd 100644
--- a/replace.el
+++ b/replace_fixed.el
@@ -2227,7 +2227,7 @@ It is called with three arguments, as if it were
            (isearch-forward (not backward))
            (isearch-other-end match-beg)
            (isearch-error nil))
-       (isearch-lazy-highlight-new-loop range-beg range-end))))
+       (save-match-data (isearch-lazy-highlight-new-loop range-beg
range-end)))))

 (defun replace-dehighlight ()
   (when replace-overlay

Then I added the following to my "~/.emacs", restarted my emacs server, and
the issue was gone!:

(load-library "~/.emacs.d/lisp/replace_fixed.el")

This probably isn't the proper fix, but just thought I'd share in case
anyone else is experiencing this and wanted a temporary workaround.

Best,
Jayden

[-- Attachment #2: Type: text/html, Size: 2138 bytes --]

  reply	other threads:[~2019-06-23 16:14 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-21 23:03 bug#36328: 26.2; Args out of range on search-and-replace of *.cc file Jayden Navarro
     [not found] ` <mailman.612.1561158667.10840.bug-gnu-emacs@gnu.org>
2019-06-22 13:25   ` Alan Mackenzie
2019-06-22 14:25     ` Jayden Navarro
2019-06-22 14:51       ` Juanma Barranquero
2019-06-22 16:09         ` Jayden Navarro
2019-06-22 20:50       ` Alan Mackenzie
2019-06-22 21:27         ` Jayden Navarro
2019-06-22 22:38           ` Jayden Navarro
2019-06-22 23:02             ` Jayden Navarro
2019-06-23 12:22             ` Alan Mackenzie
2019-06-23 16:14               ` Jayden Navarro [this message]
2019-06-23 19:32                 ` Alan Mackenzie
2019-06-23 21:19                   ` Juri Linkov
2019-06-23 21:42                     ` Jayden Navarro
2019-06-24 19:05                       ` Juri Linkov
2019-06-24 20:03                         ` Jayden Navarro
2019-06-24  7:52                     ` Alan Mackenzie
2019-06-24 19:18                       ` Juri Linkov
2019-06-25  9:47                         ` Alan Mackenzie
2019-06-25 19:58                           ` Juri Linkov
2019-07-04 21:09                             ` Juri Linkov
2019-07-05  6:11                               ` Eli Zaretskii
2019-07-05 19:12                                 ` Juri Linkov
2019-10-02 23:53                                   ` Stefan Kangas
2019-06-23 20:10 ` bug#36328: [jayden@yugabyte.com: Re: bug#36328: 26.2; Args out of range on search-and-replace of *.cc file] Alan Mackenzie

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

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

  git send-email \
    --in-reply-to='CAEKiUEZy4scEedt=3vcP=2e-9yr6cqW4QYk98DK-ajGwf_hJrA@mail.gmail.com' \
    --to=jayden@yugabyte.com \
    --cc=36328@debbugs.gnu.org \
    --cc=acm@muc.de \
    /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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.