[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Summary of message on function objects
- To: BENSON at SPA-NIMBUS, Common-Lisp%su-ai at usc-ecl
- Subject: Summary of message on function objects
- From: BENSON at SPA-NIMBUS
- Date: Tue, 10 May 1983 21:12:00 -0000
- In-reply-to: The message of 10 May 83 13:11-PDT from BENSON at SPA-NIMBUS
To summarize the important points of the previous note:
The Common Lisp manual must make clear the distinction between function
objects (lexical closures and compiled-code objects) and function names
(lambda expressions and symbols), and the evaluation process which
produces function objects from function names.
The first argument to APPLY or FUNCALL (for which FUNCTIONP is
true) must be a compiled-code object or a lexical closure. Anything
else is an error.
Lexical environments are Lisp objects which need a section in the data
types chapter. ENCLOSE takes a lambda expression and a lexical
environment and returns a lexical closure. CLOSURE-EXPRESSION takes a
lexical closure and returns the lambda expression which it encloses.
CLOSURE-ENVIRONMENT takes a lexical closure and returns the lexical
environment it was closed over.