[Top][All Lists]

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

Re: Risky local variable mechanism

From: Luc Teirlinck
Subject: Re: Risky local variable mechanism
Date: Mon, 6 Feb 2006 00:00:40 -0600 (CST)

Richard Stallman wrote:

   This seems to be a misunderstanding.  You're talking about underlying
   mechanisms; we're talking about user interfaces.

If I understand the proposed interface correctly, it would try to
update the currently customizable (through Custom) variable
safe-local-eval-forms automatically when the user visits a file.
It would create another option, customizable through Custom, for
variables and try to update that one in the same way too.

One problem for the variable list option would be that, in its
proposed form, it would only handle the variable and not the value it
is going to be set to, whereas the value is often crucial.

There are way worse problems, if the user would try to customize these
variables _through Custom_ instead of .emacs.

Customizing `safe-local-eval-forms' through Custom _already_ is
problematic right now.  The only way to avoid surprises is to
customize it in .emacs instead of through Custom.  (The reasons are
similar to those for hooks.)  The automatic updating would make the
existing problems worse and would make actually triggering the
potential problems _way_ more likely than it is now.

The two options would be listvars, whose value should not be set
using setq, like Custom does, but using add-to-list or
(setq safe-local-eval-forms (delete form safe-local-eval-forms)).

Custom can currently not handle such variables in any satisfactory
way.  The involved problems are similar to those for hooks.  There are
tons of problems we know about for hooks (but which apply equally to
this type of listvar) and whenever we discuss these problems, we find
some new ones.  We decided earlier to delay solving these problems
till after the release, because they required too radical changes in

I do not see how the automatic updating could be done in a way that
works well both for people who customize these two options in their
.emacs _and_ for people who customize them through Custom, especially
not given Custom's current problems with this type of listvars.



reply via email to

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