all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Barry Margolin <barry.margolin@level3.com>
Subject: Re: problem getting hooks to be active
Date: Mon, 11 Aug 2003 18:30:12 GMT	[thread overview]
Message-ID: <UgRZa.122$7R.48@news.level3.com> (raw)
In-Reply-To: 87ptjc3x6r.fsf@lorien.concordia.ca

In article <87ptjc3x6r.fsf@lorien.concordia.ca>,
Peter Solodov  <peter@alcor.concordia.ca> wrote:
>On 11 Aug 2003, Eric Pement wrote:
>>    (add-hook 'sgml-mode-hook'
>
>That second quote is really there???  In this case you're adding to
>"sgml-mode-hook'", and not sgml-mode-hook.

No he isn't.  Lisp has no provisions for turning single-quotes into
double-quotes.  What he wrote is actually equivalent to:

(add-hook 'sgml-mode-hook
  '(lambda ...))

because Lisp doesn't care about the presence or absence of whitespace
before or after quotes.

But I agree that his layout suggests a serious misunderstanding of how Lisp
quoting works.

>(add-hook 'sgml-mode-hook
>  (lambda ()
>    ...

That should work the same as his version, because (lambda ...) is a macro
invocation that expands into '(lambda ...).

-- 
Barry Margolin, barry.margolin@level3.com
Level(3), Woburn, MA
*** DON'T SEND TECHNICAL QUESTIONS DIRECTLY TO ME, post them to newsgroups.
Please DON'T copy followups to me -- I'll assume it wasn't posted to the group.

  parent reply	other threads:[~2003-08-11 18:30 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-08-11 17:34 problem getting hooks to be active Eric Pement
2003-08-11 17:45 ` Peter Solodov
2003-08-11 18:26   ` Johan Bockgård
2003-08-11 18:30   ` Barry Margolin [this message]
2003-08-12 16:32     ` Eric Pement
2003-08-12 16:54       ` Peter Solodov
2003-08-15 14:54         ` Eric Pement
2003-08-15 12:59 ` Kai Großjohann
2003-08-20 15:46   ` Eric Pement
2003-08-24 12:58     ` Kai Großjohann
2003-08-20 17:29   ` Eric Pement

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='UgRZa.122$7R.48@news.level3.com' \
    --to=barry.margolin@level3.com \
    /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.