From: Richard Stallman <rms@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: defvar vs setqif..
Date: Mon, 20 May 2002 15:33:22 -0600 (MDT) [thread overview]
Message-ID: <200205202133.g4KLXMI25911@aztec.santafe.edu> (raw)
In-Reply-To: <1021841986.24318.2803.camel@space-ghost> (message from Colin Walters on 19 May 2002 16:59:46 -0400)
> An example: my .emacs needs to, say, (add-hook 'foo-mode-hook... ),
> but the hook may not be defined, so i (defvar foo-mode-hook) before
> this statement.
Why do you defvar it? The best solution is to (require 'foo-mode)
before adding the hook.
That is often a costly solution, because it forces loading of
foo-mode.el. If you package always needs foo-mode, the price must be
paid anyway. But when it does not always need foo-mode, you should
not require it at load time.
next prev parent reply other threads:[~2002-05-20 21:33 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-05-19 20:44 defvar vs setqif D. Goel
2002-05-19 20:59 ` Colin Walters
2002-05-20 0:05 ` Miles Bader
2002-05-20 19:08 ` D. Goel
2002-05-20 19:41 ` Thien-Thi Nguyen
2002-05-20 19:47 ` Stefan Monnier
2002-05-21 13:13 ` D. Goel
2002-05-20 20:05 ` Kai Großjohann
2002-05-20 21:33 ` Richard Stallman [this message]
2002-05-20 0:03 ` Miles Bader
2002-05-20 19:00 ` D. Goel
2002-05-20 19:24 ` Stefan Monnier
2002-05-20 19:40 ` D. Goel
2002-05-20 23:15 ` Miles Bader
2002-05-21 13:18 ` D. Goel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200205202133.g4KLXMI25911@aztec.santafe.edu \
--to=rms@gnu.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.