From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#32991: 27.0.50; diff-auto-refine-mode a no-op Date: Sat, 13 Oct 2018 14:51:00 -0400 Message-ID: References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1539456608 14012 195.159.176.226 (13 Oct 2018 18:50:08 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 13 Oct 2018 18:50:08 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: 32991@debbugs.gnu.org To: charles@aurox.ch (Charles A. Roelli) Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Oct 13 20:50:04 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gBOzD-0003Uc-4V for geb-bug-gnu-emacs@m.gmane.org; Sat, 13 Oct 2018 20:50:03 +0200 Original-Received: from localhost ([::1]:45949 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gBP1J-0001pt-2L for geb-bug-gnu-emacs@m.gmane.org; Sat, 13 Oct 2018 14:52:13 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42735) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gBP1C-0001pk-CD for bug-gnu-emacs@gnu.org; Sat, 13 Oct 2018 14:52:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gBP19-0003aV-5S for bug-gnu-emacs@gnu.org; Sat, 13 Oct 2018 14:52:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:44359) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gBP17-0003Zy-Qe for bug-gnu-emacs@gnu.org; Sat, 13 Oct 2018 14:52:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gBP17-0000h1-La for bug-gnu-emacs@gnu.org; Sat, 13 Oct 2018 14:52:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 13 Oct 2018 18:52:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 32991 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 32991-submit@debbugs.gnu.org id=B32991.15394566742610 (code B ref 32991); Sat, 13 Oct 2018 18:52:01 +0000 Original-Received: (at 32991) by debbugs.gnu.org; 13 Oct 2018 18:51:14 +0000 Original-Received: from localhost ([127.0.0.1]:48617 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gBP0M-0000g2-Fu for submit@debbugs.gnu.org; Sat, 13 Oct 2018 14:51:14 -0400 Original-Received: from pruche.dit.umontreal.ca ([132.204.246.22]:58322) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gBP0K-0000fu-6o for 32991@debbugs.gnu.org; Sat, 13 Oct 2018 14:51:13 -0400 Original-Received: from pastel.home (lechon.iro.umontreal.ca [132.204.27.242]) by pruche.dit.umontreal.ca (8.14.7/8.14.1) with ESMTP id w9DIp0DK020807; Sat, 13 Oct 2018 14:51:01 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id 3E97C69AAE; Sat, 13 Oct 2018 14:51:00 -0400 (EDT) In-Reply-To: (Charles A. Roelli's message of "Sat, 13 Oct 2018 15:42:54 +0200") X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 2 Rules triggered EDT_SA_DN_PASS=0, RV6394=0 X-NAI-Spam-Version: 2.3.0.9418 : core <6394> : inlines <6930> : streams <1801215> : uri <2729728> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:151230 Archived-At: >> Good question. Maybe it's just not worth it and we should simply get >> rid of the old navigation-triggered refinement. This said, the new >> font-lock thingy can be problematic if the diff takes too much time >> since it happens within jit-lock with inhibit-quit set to a non-nil >> value, so it completely freezes your Emacs session, whereas if it >> happens during `n` you can stop it with C-g. >> Hopefully, we can fix this problem by calling `diff` asynchronously so >> it can't block Emacs. > I was able to produce such a case where Emacs froze for 30 seconds on > opening a 2000-line (junk) diff containing one large hunk. I bumped into one a week ago where I killed `diff` after several minutes. > Is it a matter of using "start-process" instead of "call-process"? That's the starting point, yes, but it also involves moving the "subsequent" code to the process's sentinel. >> > It could be even better if C-c C-b could interactively toggle the >> > refining of the hunk at point (for those times when the refining turns >> > out to be an eye-sore). >> Sounds good (but note that diff-refine-hunk can also be useful to >> *refresh* the fine highlighting, e.g. after manually editing a hunk). > Ok, then switching off the refining might fit better on a prefix > argument, or in a new command. Could be, tho maybe you can make it DWIM enough (i.e. turn off if there's nothing to refresh). > Good point. Maybe we could start with an ordering of just > "basic"/"basic + refine", since the diff-font-lock-prettify option is > brand new and seems to be more about hiding text than decorating it, > IIUC. Since I find font-lock-maximum-decoration fundamentally flawed, I'm rather in the business of deprecating it than increasing its use. Stefan