emacs-devel
[Top][All Lists]
Advanced

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

Re: void variable


From: Luc Teirlinck
Subject: Re: void variable
Date: Thu, 29 Jul 2004 22:21:01 -0500 (CDT)

Lars Hansen wrote:

   However, it confuses me that autoloading of variables is mentioned twice.
   So what about changing

   + If the @code{defvar} or @code{defcustom} itself is autoloaded through
   + a magic comment (@pxref{Autoload}), then there is nothing to worry
   + about: it is already initialized.  Otherwise, there are two ways to
   + prevent trouble.  You can precede the @code{defvar} or
   + @code{defcustom} with a magic comment, or you can @code{require} the
   + file before making the binding (@pxref{Named Features}).

   to

   + If the @code{defvar} or @code{defcustom} itself is autoloaded through
   + a magic comment (@pxref{Autoload}), then there is nothing to worry
   + about: it is already initialized.  Otherwise, you can @code{require} the
   + file before making the binding (@pxref{Named Features}).

I wanted to emphasize that adding an autoload, if it is not already
present, is an acceptable way to deal with the problem.  (Some people
are very reluctant to add autoloads, because they do not like to
increase the size of loaddefs.el)

What about:

    If the @code{defvar} or @code{defcustom} itself is autoloaded through
    a magic comment (@pxref{Autoload}), then there is nothing to worry
    about: it is already initialized.  Thus, adding such a magic comment is
    one way to prevent trouble.  Alternatively, you can @code{require}
    the file before making the binding (@pxref{Named Features}).

Sincerely,

Luc.




reply via email to

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