From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: defcustom problem with packages (user error?) Date: Thu, 13 Nov 2014 12:40:31 -0500 Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1415900483 26096 80.91.229.3 (13 Nov 2014 17:41:23 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 13 Nov 2014 17:41:23 +0000 (UTC) Cc: Artur Malabarba , emacs-devel To: Elias =?windows-1252?Q?M=E5rtenson?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Nov 13 18:41:15 2014 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XoyOR-0006Cv-7j for ged-emacs-devel@m.gmane.org; Thu, 13 Nov 2014 18:41:15 +0100 Original-Received: from localhost ([::1]:33140 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XoyOQ-0004bQ-PH for ged-emacs-devel@m.gmane.org; Thu, 13 Nov 2014 12:41:14 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44998) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XoyOG-0004ZI-CY for emacs-devel@gnu.org; Thu, 13 Nov 2014 12:41:12 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XoyO8-00010a-52 for emacs-devel@gnu.org; Thu, 13 Nov 2014 12:41:04 -0500 Original-Received: from mercure.iro.umontreal.ca ([132.204.24.67]:48599) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XoyO8-00010R-0t for emacs-devel@gnu.org; Thu, 13 Nov 2014 12:40:56 -0500 Original-Received: from hidalgo.iro.umontreal.ca (hidalgo.iro.umontreal.ca [132.204.27.50]) by mercure.iro.umontreal.ca (Postfix) with ESMTP id B4C66850C0; Thu, 13 Nov 2014 12:40:55 -0500 (EST) Original-Received: from lechon.iro.umontreal.ca (lechon.iro.umontreal.ca [132.204.27.242]) by hidalgo.iro.umontreal.ca (Postfix) with ESMTP id C6D191E5B8B; Thu, 13 Nov 2014 12:40:31 -0500 (EST) Original-Received: by lechon.iro.umontreal.ca (Postfix, from userid 20848) id AC1A9B40E9; Thu, 13 Nov 2014 12:40:31 -0500 (EST) In-Reply-To: ("Elias =?windows-1252?Q?M=E5rtenson=22's?= message of "Thu, 13 Nov 2014 21:03:09 +0800") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) X-DIRO-MailScanner-Information: Please contact the ISP for more information X-DIRO-MailScanner: Found to be clean X-DIRO-MailScanner-SpamCheck: n'est pas un polluriel, SpamAssassin (score=-2.82, requis 5, autolearn=not spam, ALL_TRUSTED -2.82, MC_TSTLAST 0.00) X-DIRO-MailScanner-From: monnier@iro.umontreal.ca X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 132.204.24.67 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:176979 Archived-At: > 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