|
From: | Noam Postavsky |
Subject: | bug#35316: 26.2; Emacs lags in c++-mode buffer when editing with iedit-mode on |
Date: | Sun, 19 May 2019 09:20:16 -0400 |
User-agent: | Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) |
Alan Mackenzie <acm@muc.de> writes: > (defun iedit-update-occurrences-2 (occurrence after beg end &optional change) > "" > - (let ((inhibit-modification-hooks t) > + (let (;; (inhibit-modification-hooks t) > + ;; Note: `inhibit-modification-hook' will already be non-nil when > this > + ;; function is called. Setting it to nil here doesn't work. By "doesn't work", do you mean that it would trigger an infloop? Would something like this work: (defvar iedit-inhibit-update nil) (defun iedit-update-occurrences-2 (occurrence after beg end &optional change) ... ;; Let other modification hooks run, but don't recurse infinitely. (unless iedit-inhibit-update (let ((inhibit-modification-hooks nil) (iedit-inhibit-update t)) ... See also Bug#25111 "How modification-hooks let-bind inhibit-modification-hooks?" https://debbugs.gnu.org/25111
[Prev in Thread] | Current Thread | [Next in Thread] |