emacs-devel
[Top][All Lists]
Advanced

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

Re: Comments on setopt


From: Stefan Monnier
Subject: Re: Comments on setopt
Date: Tue, 15 Feb 2022 08:15:10 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

>> - As `customize-set-variable' is being used directly, the "user" theme
>>   is modified, and a customisation might be mirrored in
>>   `custom-set-variables'.  This can lead to the unfortunate situation
>>   where your setopt configuration is overriden by the
>>   `custom-set-variables', depending on when and how you load `custom-file'
>>   and when and how the `custom-set-variables' was generated.
>
> Isn't that the case no matter how these variables are set?  It depends
> on the order.

No.  If you set the variable with `setq` Custom will notice that it was
set "outside of Custom" and thus refrain from saving the value into its
`customize-set-variables` block.

>> - While I don't mind it really, I can imagine that others might object
>>   to the "long" name, when compared to setq.  Would a default alias like
>>   "seto" or "setc" be worth it or not?
> I think `seto' is confusing, and `setc' doesn't really tell you
> anything.  The salient thing is that we're setting user option, not that
> it's been defined by `defcustom'.

FWIW, it took me a while to understand what "long name" Philip was
talking about because I assumed `setopt` wouldn't be considered as
long.  ;-)


        Stefan




reply via email to

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