emacs-devel
[Top][All Lists]
Advanced

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

Re: Average-user-facing interface for tree-sitter


From: Stefan Monnier
Subject: Re: Average-user-facing interface for tree-sitter
Date: Thu, 27 Oct 2022 11:21:06 -0400
User-agent: Gnus/5.13 (Gnus v5.13)

>> Yes, there are indeed some non-trivial tradeoffs here.
>
> Reading some old bug report made me realize another problem: what if
> a derived-mode of js-mode, A-mode expects cc-mode stuff to be setup by
> js-mode, but js-mode doesn’t setup cc-mode because it’s using tree-sitter?
>
> But if A-mode uses tree-sitter too, then it wouldn’t want js-mode to setup
> cc-mode. So it seems A-mode needs a way to control whether it wants its
> parent mode(s) to setup tree-sitter or not.
>
> One way would be adding another flag in treesit-settings, which controls
> whether this mode’s parent should setup tree-sitter.

Sounds too hypothetical to make a good decision on what should be done
about it.  Let's cross that bridge when we get there.  In the mean time
I think it's perfectly acceptable to say "don't do that if it hurts".


        Stefan




reply via email to

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