[Top][All Lists]

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

Re: Predicate for true lists

From: Daniel Colascione
Subject: Re: Predicate for true lists
Date: Tue, 9 Apr 2019 09:54:48 -0700
User-agent: SquirrelMail/1.4.23 [SVN]

>> --- a/src/fns.c
>> +++ b/src/fns.c
>> @@ -5326,6 +5326,12 @@ syms_of_fns (void)
>>    DEFSYM (Qcursor_in_echo_area, "cursor-in-echo-area");
>>    DEFSYM (Qwidget_type, "widget-type");
>> +  DEFSYM (Qpure, "pure");
>> +  DEFSYM (Qside_effect_free, "side-effect-free");
>> +  DEFSYM (Qproper_list_p, "proper-list-p");
>> +  Fput (Qproper_list_p, Qpure, Qt);
>> +  Fput (Qproper_list_p, Qside_effect_free, Qt);
> I think you can set the side-effect-free property to `error-free`, which
> is stronger.  Other than that, it looks OK (tho I personally find doing it
> in C to be too painful, so I prefer moving this kind of code to subr.el).
>> I also attach a second patch which moves the proper-list-p tests to the
>> correct file following the function's rewriting in C.  WDYT?

I'd also prefer to put new functionality in lisp when possible. We're
going to get a JIT one day, and when we do, lisp functionality may very
well end up *faster* than C stuff anyway due to specialization and
tracing. In the meantime, lisp performance is adequate, and if we can keep
the C core small, we should.

reply via email to

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