emacs-devel
[Top][All Lists]
Advanced

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

Re: master 09b5f00613: ; Fix calls to treesit functions


From: Stefan Monnier
Subject: Re: master 09b5f00613: ; Fix calls to treesit functions
Date: Mon, 19 Dec 2022 23:37:28 -0500
User-agent: Gnus/5.13 (Gnus v5.13)

> SGTM, but I think we should document somewhere how does one write a
> Lisp program that could optionally use tree-sitter, i.e. which APIs
> text for the availability of tree-sitter support internally, and thus
> could serve as a gate-keepers.

I think this can be done simply by listing which functions are always
defined.  Then we just have to make sure that those functions can be
implemented correctly even without Tree-sitter.  This is the case for
example for `treesit-node-at` and `treesit-parser-list` (where nil is
the correct answer when Tree-sitter is absent) .


        Stefan




reply via email to

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