emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Use (eval-when-compile 'treesit) to save us from writing declare-fun


From: Stefan Monnier
Subject: Re: Use (eval-when-compile 'treesit) to save us from writing declare-function forms
Date: Sun, 08 Dec 2024 21:40:29 -0500
User-agent: Gnus/5.13 (Gnus v5.13)

> I thought eval-when-compile is more of a “include if compiling” macro, 
> should’ve checked :)
>
> We can also go with Dmitry’s idea, and just define all the functions in
> treesit.el if Emacs is not built with tree-sitter. We can detect that with
> treesit-available-p.

I haven't really thought about it, so I don't have a strong opinion.
AFAICT your proposal should work fine even if you remove the
`eval-when-compile` wrappers to which I objected.  🙂


        Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]