Steve Haflich wrote:
>
> Starting in 4.3 closures are stack consed if either the compiler can
> prove them to be dynamic extent, or if you declare them
> DYNAMIC-EXTENT. This greatly reduces consing in some circumstances
> without requiring that pretty functional code be rewritten in an
> ungly, unclear way.
#1) when will we (if ever) see these improvements in ACLWIN?
#2) what is the correct way to declare dynamic-extent for lambda
expressions? (i.e., #'(lambda (i) ...)) or will the compiler assume
dynamic-extent when the lambda is an arg to such functions as some,
funcall, etc. (from which the lambda is not returned).
#3) what is the correct way to declare dynamic-extent for flet or labels
defined functions? In mcl, you must use #' but I don't know about other
compilers. That is,
(flet ((my-fun (i) ...))
(declare (dynamic-extent #'my-fun))
...)
works but (... (dynamic-extent my-fun) ...) does not.
Thanks.
--
Donald H. Mitchell <pgh.net at dhm>
Proactive Solutions, Inc. 412.835.2410
5858 Horseshoe Dr. 412.835.2411 (fax)
Bethel Park, PA 15102