GNU bug report logs - #70059
30.0.50; c-ts-mode crashes emacs

Previous Next

Package: emacs;

Reported by: Felix <felix.dick <at> web.de>

Date: Thu, 28 Mar 2024 20:38:01 UTC

Severity: normal

Found in version 30.0.50

Full log


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

From: Yuan Fu <casouri <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: felix.dick <at> web.de, 70059 <at> debbugs.gnu.org
Subject: Re: bug#70059: 30.0.50; c-ts-mode crashes emacs
Date: Tue, 2 Apr 2024 11:20:27 -0700

> On Mar 31, 2024, at 12:43 AM, Eli Zaretskii <eliz <at> gnu.org> wrote:
> 
>> From: Yuan Fu <casouri <at> gmail.com>
>> Date: Sat, 30 Mar 2024 22:52:55 -0700
>> Cc: Felix <felix.dick <at> web.de>,
>> 70059 <at> debbugs.gnu.org
>> 
>> It’s a bit strange since Ftreesit_pattern_expand doesn’t call tree-sitter function. This function just expands a sexp query like '(function_definition @capture) to a string “(function_definition @capture)”. 
> 
> I'm not sure I follow: the backtrace shows that
> Ftreesit_pattern_expand called Fmapconcat, and I do see a call to
> Fmapconcat in Ftreesit_pattern_expand.  So what did you mean by
> "Ftreesit_pattern_expand doesn't call tree-sitter function"?

I should've been more precise, I mean it doesn’t call functions from tree-sitter library.

> 
>> Perhaps something it does triggers GC and GC tries to collect some tree-sitter node or parser, and there’s some problem when freeing the node or parser with that version of tree-sitter library.
> 
> Again, not sure I follow: according to the backtrace, Fmapconcat
> called mapconcat1, which called Ffuncall.  And Ffuncall is known to
> trigger GC if needed.

Ah, I didn’t know it, thanks for explaining that.

Yuan





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

Previous Next


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