GNU bug report logs - #67977
30.0.50; tree-sitter: Emacs crashes when accessing treesit-nodes in a narrowed buffer

Previous Next

Package: emacs;

Reported by: Denis Zubarev <dvzubarev <at> yandex.ru>

Date: Fri, 22 Dec 2023 23:19:02 UTC

Severity: normal

Found in version 30.0.50

Fixed in version 30.1

Done: Yuan Fu <casouri <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #32 received at 67977 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Dmitry Gutov <dmitry <at> gutov.dev>
Cc: casouri <at> gmail.com, dvzubarev <at> yandex.ru, 67977 <at> debbugs.gnu.org
Subject: Re: bug#67977: 30.0.50; tree-sitter: Emacs crashes when accessing
 treesit-nodes in a narrowed buffer
Date: Thu, 28 Dec 2023 15:53:34 +0200
> Date: Thu, 28 Dec 2023 13:44:43 +0200
> Cc: Denis Zubarev <dvzubarev <at> yandex.ru>, 67977 <at> debbugs.gnu.org
> From: Dmitry Gutov <dmitry <at> gutov.dev>
> 
> >> Could font-lock-dont-widen help, perhaps?
> > Yes. If font-lock doesn’t widen, then there wouldn’t be back-and-forth reparses.
> 
> But then treesit major modes will be affected by user narrowing (e.g. if 
> the user narrowed to inside the string, the buffer won't be highlighted 
> as a string).

Why is that a problem?  When the user narrows the buffer, the part
outside the narrowing doesn't exist as far as Emacs is concerned.




This bug report was last modified 1 year and 44 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.