Subject: bug#77256: Treesit language-at-point

From: Stefan Monnier <[email-masked]>
Date: Tue, 08 Apr 2025 15:52:08 -0400

>> 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`.
>
> Unfortunately, it's too late to add a non-nil default value.

Is it?
I can't find any code out there that seems to care what is its default
value (all users set it but doesn't look at it, AFAICT).

> I already tried to do the same by adding 'forward-sexp-default-function'
> to 'forward-sexp-function', but failed spectacularly (bug#70426),

Yes, that one is much harder (it's one of the first I tried to change),

        Stefan