all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Juanma Barranquero" <lekktu@gmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: Special treatment of `term-setup-hook'
Date: Thu, 7 Dec 2006 17:31:13 +0100	[thread overview]
Message-ID: <f7ccd24b0612070831k21eaaf0y7a56811e89362e13@mail.gmail.com> (raw)
In-Reply-To: <m3mz5zele6.fsf@kfs-l.imdomain.dk>

On 12/7/06, Kim F. Storm <storm@cua.dk> wrote:

> They are different if x is not bound.

Well, of course, if you don't mind getting and error :) I expect
people would write either:

 (if (boundp 'x)
      (run-hooks 'x)
    ; error or whatever

or

  (and (boundp 'x)
       x
       (run-hooks 'x))

or, nowadays:

  (when (bound-and-true-p 'x)
     (run-hooks 'x))

which seem clearer for that specific purpose.

> But for the case at hand, I don't see the difference either...

That's what puzzles me.  I don't understand why someone would add (and
term-setup-hook (run-hooks 'term-setup-hook)) instead of the simpler
alternative. But someone did, and I suppose he had a good reason...

That's all idle thinking, of course.

                    /L/e/k/t/u

      reply	other threads:[~2006-12-07 16:31 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-10-24  9:02 Special treatment of `term-setup-hook' Juanma Barranquero
2006-12-07  1:07 ` Juanma Barranquero
2006-12-07  4:22   ` Eli Zaretskii
2006-12-07 15:58     ` Juanma Barranquero
2006-12-07 16:11       ` Kim F. Storm
2006-12-07 16:31         ` Juanma Barranquero [this message]

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=f7ccd24b0612070831k21eaaf0y7a56811e89362e13@mail.gmail.com \
    --to=lekktu@gmail.com \
    --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.