emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] [RFC] Change some defcustoms into defcont


From: Nicolas Goaziou
Subject: Re: [O] [RFC] Change some defcustoms into defcont
Date: Mon, 21 Oct 2013 12:51:55 +0200

Carsten Dominik <address@hidden> writes:

> On 21.10.2013, at 10:56, Nicolas Goaziou <address@hidden> wrote:

>> That's exactly the point of the defconst: you can still modify the
>> variable, but it sends a strong message to the user. Also, it's not
>> about deprecation: code base should still rely on these variables.
>
> This is where I disagree.  I think the Emacs implementation of defconst
> is broken, and retained in this way only for backward compatibility.

I won't judge Elisp implementation. AFAIC, defining a variable as
a defconst means : "change it at your own risk", which is exactly my
point.

Anyway, FWIW, even a defvar would suffice.

> If we still allow users to edit this in principle,

We have no way to prevent them from modifying it. In principle, they
mustn't be changed, but it's Free software.

> I do not think we should make these variables defconst. If editing is
> not even depreciated, there is even less reason to make this change.
> How about we add a sentence like this:
>
> Changing this variable may cause compatibility problems with other users
> trying to edit your file in Emacs.

It's not only about compatibility problems. As I pointed out, modifying
these variable can break your own Org.

Using a defcustom is ambiguous here. On the one hand, we say "You can
modify this variable, we even help you to do so" and on the other hand
"Upon changing this variable, horrible things can happen".

Let's, at least, not help users shoot themselves in the foot.


Regards,

-- 
Nicolas Goaziou



reply via email to

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