newLISP Fan Club

Forum => Anything else we might add? => Topic started by: HPW on January 29, 2006, 10:32:50 AM

Title: lambda and fn missing in (symbols)
Post by: HPW on January 29, 2006, 10:32:50 AM
lambda and fn are missing in the return of (symbols).

Are they no primitives?

(Found on building keyword-lists for highlighting)
Title:
Post by: Lutz on January 29, 2006, 12:30:03 PM
They are not really primitives, but rather a special type of a list, for that reason:



> (empty? '(fn))
true
> (first '(fn (x) (+ x x))) ;; not 'fn'
(x)
>


but in editos they definitely should be highlighted, as well as 'nil' and 'true'



Lutz



ps: see also http://newlisp.org/downloads/newlisp_manual.html#lambda_expressions , and I added lambda and fn to doc/keywords.txt