X-Loop: help-debbugs@HIDDEN Subject: bug#60427: Emacs-29, c++-ts-mode: typing "char" into an empty buffer causes an exception in redisplay. Resent-From: Alan Mackenzie <acm@HIDDEN> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> Resent-CC: bug-gnu-emacs@HIDDEN Resent-Date: Fri, 30 Dec 2022 12:25:01 +0000 Resent-Message-ID: <handler.60427.B.167240310024598 <at> debbugs.gnu.org> Resent-Sender: help-debbugs@HIDDEN X-GNU-PR-Message: report 60427 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 60427 <at> debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@HIDDEN Received: via spool by submit <at> debbugs.gnu.org id=B.167240310024598 (code B ref -1); Fri, 30 Dec 2022 12:25:01 +0000 Received: (at submit) by debbugs.gnu.org; 30 Dec 2022 12:25:00 +0000 Received: from localhost ([127.0.0.1]:33675 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1pBERX-0006Og-LA for submit <at> debbugs.gnu.org; Fri, 30 Dec 2022 07:24:59 -0500 Received: from lists.gnu.org ([209.51.188.17]:43666) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <acm@HIDDEN>) id 1pBERV-0006OY-E3 for submit <at> debbugs.gnu.org; Fri, 30 Dec 2022 07:24:58 -0500 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 <acm@HIDDEN>) id 1pBERS-0002kR-5Z for bug-gnu-emacs@HIDDEN; Fri, 30 Dec 2022 07:24:56 -0500 Received: from mx3.muc.de ([193.149.48.5]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <acm@HIDDEN>) id 1pBERQ-0007nP-9I for bug-gnu-emacs@HIDDEN; Fri, 30 Dec 2022 07:24:53 -0500 Received: (qmail 72923 invoked by uid 3782); 30 Dec 2022 13:24:39 +0100 Received: from acm.muc.de (p4fe15ce1.dip0.t-ipconnect.de [79.225.92.225]) (using STARTTLS) by colin.muc.de (tmda-ofmipd) with ESMTP; Fri, 30 Dec 2022 13:24:38 +0100 Received: (qmail 14856 invoked by uid 1000); 30 Dec 2022 12:24:38 -0000 Date: Fri, 30 Dec 2022 12:24:38 +0000 Message-ID: <Y67YhlqC9GENlILo@ACM> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Submission-Agent: TMDA/1.3.x (Ph3nix) From: Alan Mackenzie <acm@HIDDEN> X-Primary-Address: acm@HIDDEN Received-SPF: pass client-ip=193.149.48.5; envelope-from=acm@HIDDEN; helo=mx3.muc.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.4 (-) X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -2.4 (--) Hello, Emacs. In the emacs-29 branch, with the latest commit being: commit 558b59d81b938fc434e62523106360b9704c88e2 (HEAD -> emacs-29, origin/emacs-29, origin/HEAD) Author: Yuan Fu <casouri@HIDDEN> Date: Thu Dec 29 11:52:06 2022 -0800 Add color fontification in css-ts-mode (bug#60405) : (i) emacs -Q (ii) (setq backtrace-on-redisplay-error t) (iii) C-x b string.cc <RET> (iv) M-x c++-ts-mode <RET> (v) Type "char" (without the quote marks). This throws an exception in the redisplay code. The backtrace in the *Redisplay-trace* buffer is: Error: treesit-query-error ("Node type error at" 195 "Debug the query with `treesit-query-validate'") debug-early-backtrace() debug-early(error (treesit-query-error "Node type error at" 195 "Debug the query with `treesit-query-validate'")) treesit-font-lock-fontify-region(1 5 nil) font-lock-default-fontify-region(1 5 nil) font-lock-fontify-region(1 5) #f(compiled-function (fun) #<bytecode -0x156ee3e72a1d5e83>)(font-lock-fontify-region) jit-lock--run-functions(1 5) jit-lock-fontify-now(1 5) jit-lock-function(1) redisplay_internal\ \(C\ function\)() .. That this insertion causes an exception is clearly a bug. But the contents of the backtrace seem to me to be less helpful than they might be. What does the "the" in "the query" refer to? There is no referent yet established. What does the 195 refer to? It clearly isn't a buffer position, which is what it would mean in lots of other Emacs error messages. Just as a matter of interest, in c-ts-mode, the above actions run without problem. -- Alan Mackenzie (Nuremberg, Germany).
Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) Content-Type: text/plain; charset=utf-8 X-Loop: help-debbugs@HIDDEN From: help-debbugs@HIDDEN (GNU bug Tracking System) To: Alan Mackenzie <acm@HIDDEN> Subject: bug#60427: Acknowledgement (Emacs-29, c++-ts-mode: typing "char" into an empty buffer causes an exception in redisplay.) Message-ID: <handler.60427.B.167240310024598.ack <at> debbugs.gnu.org> References: <Y67YhlqC9GENlILo@ACM> X-Gnu-PR-Message: ack 60427 X-Gnu-PR-Package: emacs Reply-To: 60427 <at> debbugs.gnu.org Date: Fri, 30 Dec 2022 12:25:01 +0000 Thank you for filing a new bug report with debbugs.gnu.org. This is an automatically generated reply to let you know your message has been received. Your message is being forwarded to the package maintainers and other interested parties for their attention; they will reply in due course. Your message has been sent to the package maintainer(s): bug-gnu-emacs@HIDDEN If you wish to submit further information on this problem, please send it to 60427 <at> debbugs.gnu.org. Please do not send mail to help-debbugs@HIDDEN unless you wish to report a problem with the Bug-tracking system. --=20 60427: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D60427 GNU Bug Tracking System Contact help-debbugs@HIDDEN with problems
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd,
1994-97 Ian Jackson.