4 ms·
(funcall #'+ ...) does not do a symbol lookup and does not need to retrieve the function from a symbol in Common Lisp. (funcall '+ ...) would retrieve the funct
by lispm 10y ago
(funcall #'+ ...) does not do a symbol lookup and does not need to retrieve the function from a symbol in Common Lisp. (funcall '+ ...) would retrieve the function from the symbol.
Treeshakers are generally used for application delivery in Lisp. When you do that, then one usually limits the amount of use of runtime dynamics. Typically you can tell the treeshaker what to remove or what to keep: the compiler, the symbol table, debugging info, etc etc.
Allegro CL and LispWorks have extensive facilities for this.
http://franz.com/support/documentation/10.0/doc/delivery.htm http://franz.com/support/documentation/10.0/doc/delivery.htm
http://www.lispworks.com/documentation/lw70/DV/html/delivery.htm http://www.lispworks.com/documentation/lw70/DV/html/delivery...
- kazinator 10y agoMore briefly, in a half decent implementation, the + symbol is involved in the processing of (funcall #'+ ...) in the same ways and at the same times as it is involved in the plain call (+ ...).