From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#61215: 29.0.60; font-lock broken in diff-mode with long lines Date: Fri, 31 Mar 2023 10:10:20 +0300 Organization: LINKOV.NET Message-ID: <861ql51jl2.fsf@mail.linkov.net> References: <86lelh6yhq.fsf_-_@mail.linkov.net> <83cz6tz12b.fsf@gnu.org> <86o7qcf2x5.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="25357"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/30.0.50 (x86_64-pc-linux-gnu) Cc: Eli Zaretskii , 61215@debbugs.gnu.org To: Gregory Heytings Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Mar 31 09:17:24 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pi90m-0006Mk-FC for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 31 Mar 2023 09:17:24 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pi90V-0007A0-7P; Fri, 31 Mar 2023 03:17:07 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pi90S-00079b-BZ for bug-gnu-emacs@gnu.org; Fri, 31 Mar 2023 03:17:04 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pi90R-0002mp-1j for bug-gnu-emacs@gnu.org; Fri, 31 Mar 2023 03:17:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pi90Q-00045h-Cb for bug-gnu-emacs@gnu.org; Fri, 31 Mar 2023 03:17:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 31 Mar 2023 07:17:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61215 X-GNU-PR-Package: emacs Original-Received: via spool by 61215-submit@debbugs.gnu.org id=B61215.168024697015661 (code B ref 61215); Fri, 31 Mar 2023 07:17:02 +0000 Original-Received: (at 61215) by debbugs.gnu.org; 31 Mar 2023 07:16:10 +0000 Original-Received: from localhost ([127.0.0.1]:60216 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pi8zZ-00044X-Qc for submit@debbugs.gnu.org; Fri, 31 Mar 2023 03:16:10 -0400 Original-Received: from relay7-d.mail.gandi.net ([217.70.183.200]:40709) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pi8zY-00043u-0t for 61215@debbugs.gnu.org; Fri, 31 Mar 2023 03:16:08 -0400 Original-Received: (Authenticated sender: juri@linkov.net) by mail.gandi.net (Postfix) with ESMTPSA id 17D2320009; Fri, 31 Mar 2023 07:15:58 +0000 (UTC) In-Reply-To: (Gregory Heytings's message of "Thu, 30 Mar 2023 23:22:20 +0000") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:258974 Archived-At: >> 1. (setq debug-on-error t backtrace-on-redisplay-error t) >> 2. Create a commit with some diff hunks in a prog mode at the beginning, and a single-line 1MB file added at the end; >> 3. From *vc-change-log* type `d' on that commit that opens *vc-diff* buffer >> 4. Scroll the *vc-diff* buffer >> >> It displays an error in the *Warning* buffer: >> >> ⛔ Warning (error): Error in a redisplay Lisp hook. See buffer *Redisplay_trace* > > I did, in the Emacs repository: > > echo README >> README > echo CONTRIBUTE >> CONTRIBUTE > echo INSTALL >> INSTALL Actually, these files can't expose the problem. I suggest to use a mode with complex font-lock rules for syntax highlighting. I tested with a few of 1-char edits in a few places inside an .el file. > git add a.xml The diff will output the file name a.xml at the beginning, but better to output it after the file with changes. The complete diff output should look like this: first a few diff hunks each with 1-line change from an .el file with syntax fontification. Then at the end of the screen the huge file added in the same commit. > git commit -a -m commit > ./src/emacs -Q --eval '(setq debug-on-error t backtrace-on-redisplay-error t)' > C-x v l > d Not sure if this shows diffs only from one file. More reliable would be to use 'C-x v L d' to show a multi-file commit. > At that point there are no errors, and the a.xml hunk is correctly > fontified. Now if I do: > > q > d > > then the errors you mention above appear (and the a.xml hunk is not > correctly fontified anymore). If I manually kill the *vc-diff* buffer, > they disappear again. Is this also what you see? Hmm, I tried again, and can't reproduce it in emacs-29. But in master there are still the same errors. How this is possible when emacs-29 is merged to master?