emacs-devel
[Top][All Lists]
Advanced

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

Re: Make all tree-sitter modes optional


From: Stefan Monnier
Subject: Re: Make all tree-sitter modes optional
Date: Wed, 15 Feb 2023 14:26:25 -0500
User-agent: Gnus/5.13 (Gnus v5.13)

>>> out again is unreasonably difficult.  Even restarting Emacs (which to me
>>> is a drastic operation) won't opt out if there are still buffers in
>>> c-ts-mode in the desktop.
>> Sounds like a bug, indeed.
>> The `add-to-list` should not happen just because `c-ts-mode` is loaded.
>> I think it should only happen if `c-ts-mode` is called explicitly
>> (i.e. interactively).
>
> That would make this disruptive behavior even less useful, though, because
> one of the suggested ways to use it was to add (require 'c-ts-mode) to the
> user's init script -- to have the auto-mode-alist settings applied.

We should never recommend (require <foo>) as a way to change Emacs's
behavior, since it directly conflicts with our convention that loading
a file should not significantly alter Emacs's behavior.

OTOH we can expose&preload `c-ts--activate` and tell users to use

    (cs-ts-activate)

in their `.emacs` (or use another name for it, of course).


        Stefan




reply via email to

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