emacs-pretest-bug
[Top][All Lists]
Advanced

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

Re: Some libraries does (require 'cl)


From: Lennart Borgman (gmail)
Subject: Re: Some libraries does (require 'cl)
Date: Sat, 19 May 2007 03:21:21 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.3) Gecko/20070326 Thunderbird/2.0.0.0 Mnenhy/0.7.5.666

Richard Stallman wrote:
    Some libraries (iswitchb.el for example) does

       (require 'cl)

    without (eval-when-compile ...). Is not that incorrect?

It is incorrect, in general.  However, in the case of iswitchb,
it is a no-op:

    ;; CL needed for cadr and last
    (if (not (and (fboundp 'cadr)
                  (fboundp 'last)))
        (require 'cl))

The current Emacs has `cadr' and `last' as primitives, so cl
will never be loaded.

There are some more in a comment I made to this in another message.

However there is one thing I do not understand and that other people have asked: If one want to use functions from cl.el (not only macros), how does one do then? Is (eval-when-compile (require 'cl)) sufficient then?





reply via email to

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