emacs-devel
[Top][All Lists]
Advanced

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

Re: defcustom problem with packages (user error?)


From: Stefan Monnier
Subject: Re: defcustom problem with packages (user error?)
Date: Thu, 13 Nov 2014 12:40:31 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

> That said, if it's not a good idea to autoload customisable variables, then
> what is the purpose of `custom-autoload'? This is what gets inserted into
> gnu-apl-mode-autoloads.el.

Some variables are "autoloaded", which basically means their definition
is copied to the autoloads file.  So far this has mostly been used for
lisp/loaddefs.el, i.e. int he case for the "autoloads" file gets loaded
once and forall during the dump process, long before the user's .emacs
and customizations can be involved.

Such autoloaded variables are generally a bad idea, but occasionally
they're useful so that other packages can use the var's value without
having to `require' the package where the var happens to be declared.

This said, most of those autoloaded variables are mistakes that we live
with because once it's autoloaded, it's predefined and hence packages
and .emacs files out there rely on the variable being always defined,
and de-autoloading it would break backward compatibility.

The custom-autoload thingy exists so that autoloaded custom vars don't
cost as much as if the full defcustom was copied into the loaddefs.el
file, IIRC.


        Stefan



reply via email to

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