help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Canonical add-hook idiom


From: Henrik Enberg
Subject: Re: Canonical add-hook idiom
Date: Sat, 15 Nov 2003 19:27:43 +0100
User-agent: Gnus/5.1003 (Gnus v5.10.3) Emacs/21.3.50 (gnu/linux)

Oliver Scholz <address@hidden> writes:

> Bob Nelson <address@hidden> writes:
>
>> What is the preferred approach given these examples:
>>
>>     1). (add-hook 'some-mode-hook (lambda () [...]
>
> I definitely prefer (1).
>
> Some would prefer #'(lambda () ...), which for the Lisp interpreter
> is the same as (3).  But AFAIK this is just a Common Lisp idiom and
> it makes no difference in Emacs Lisp.

In addition using #'(lambda () ...) or '(lambda () ...) means the lambda
form won't be compiled if the file is.


reply via email to

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