emacs-devel
[Top][All Lists]
Advanced

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

Re: Should mode commands be idempotent?


From: Stefan Monnier
Subject: Re: Should mode commands be idempotent?
Date: Sat, 23 Sep 2017 10:17:21 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux)

> It isn't even obvious that the current behavior (even with your patch) is
> what we want, anyway: what if I have another mode foo-mode that touches the
> same variables as visual-line-mode? Then I can run (visual-line-mode),
> (foo-mode), (visual-line-mode -1), and then which state should I be in?
> There's a more general problem here, and it's not an easy one :/

I know.  We need something along the same lines as add-function but for
arbitrary values rather than only for functions.  It was pretty close to
the top of my todo list recently (close enough that I thought about it,
but not close enough to get usable code out of it).


        Stefan




reply via email to

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