GNU bug report logs - #77256
Treesit language-at-point

Previous Next

Package: emacs;

Reported by: Juri Linkov <juri <at> linkov.net>

Date: Tue, 25 Mar 2025 18:44:02 UTC

Severity: normal

Fixed in version 31.0.50

Done: Juri Linkov <juri <at> linkov.net>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Yuan Fu <casouri <at> gmail.com>
Cc: 77256 <at> debbugs.gnu.org, Vincenzo Pupillo <v.pupillo <at> gmail.com>, Juri Linkov <juri <at> linkov.net>
Subject: bug#77256: Treesit language-at-point
Date: Tue, 08 Apr 2025 14:22:01 -0400
>>   (if treesit-language-at-point-function
>>       (funcall treesit-language-at-point-function position)

BTW, can we please avoid this anti-pattern?
Instead, we should unconditionally call
`treesit-language-at-point-function` and give a non-nil default value to
this variable.

This would make sure the `treesit-language-at-point-function` is good
enough to implement the default behavior and it makes it possible to use
`add-function` on `treesit-language-at-point-function`.


        Stefan





This bug report was last modified 92 days ago.

Previous Next


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