emacs-devel
[Top][All Lists]
Advanced

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

Re: CL package serious deficiencies


From: Lennart Borgman
Subject: Re: CL package serious deficiencies
Date: Wed, 8 Feb 2012 16:43:53 +0100

On Wed, Feb 8, 2012 at 16:39, Eric Schulte <address@hidden> wrote:
> Lennart Borgman <address@hidden> writes:
>
>> On Wed, Feb 8, 2012 at 14:51, Eric Schulte <address@hidden> wrote:
>>>>>
>>>>> org-count
>>>>> org-find-if
>>>>> org-reduce
>>>>> org-remove-if
>>>>> org-remove-if-not
>>>>
>>>> I must be misremembering. Isn't it ok to use the cl functions here?
>>>> (You would be using it in compiled code.)
>>>>
>>>
>>> You are misremembering.  If it were ok org, gnus, ert and widget would
>>> not all have their own remove-if variants?
>>
>> Thanks. Or, I might be misunderstanding ;-)
>> The manual says in D.1 Emacs Lisp Coding Conventions that
>>
>>     However, there is no problem with using the `cl' package at
>>      compile time, with `(eval-when-compile (require 'cl))'.  That's
>>      sufficient for using the macros in the `cl' package, because the
>>      compiler expands them before generating the byte-code.
>>
>> Is that not enough, or is it not applicable to code included in Emacs?
>>
>
> The above only applies to *macros* which are expanded at compile time.
> The expanded macros leave no reference to cl in the resulting compiled
> code.  On the contrary cl functions (even in compiled code) when called
> at runtime still require cl to be loaded and available at runtime.
>
> Hope this makes it clear,

Yes, I have not looked much at cl.el and my impression was that only
the macros were important. So I was mistaken there.



reply via email to

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