Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Lisp > Re: Capturing a...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 14 of 15 Topic 13120 of 13602
Post > Topic >>

Re: Capturing a function in a closure

by Kent M Pitman <pitman@[EMAIL PROTECTED] > Jul 24, 2008 at 07:26 PM

pjb@[EMAIL PROTECTED]
 (Pascal J. Bourguignon) writes:

> Barry Margolin <barmar@[EMAIL PROTECTED]
> writes:
> ...
> > (let ((orig-list #'list))
> >   (defun my-list (&rest args) (apply orig-list args)))
> 
> The problem with closures is that they don't go well thru .fasl files...
> That's why it's better to use LOAD-TIME-VALUE.

There's no compile-time closure happening here.  The LET is evaluated
at execution time (i.e., at load time).  No closure ends up in a FASL
file with the above code.  The DEFUN does create a closure, but not
until load time. (The definition of MY-LIST is presumably not
inlineable even if there is an INLINE definition prior to the above
code not shown in the example.)
 




 15 Posts in Topic:
Capturing a function in a closure
Glenn Willen <gwillen@  2008-07-22 21:10:44 
Re: Capturing a function in a closure
Pascal Costanza <pc@[E  2008-07-22 21:25:13 
Re: Capturing a function in a closure
Glenn Willen <gwillen@  2008-07-22 21:35:38 
Re: Capturing a function in a closure
Rainer Joswig <joswig@  2008-07-22 21:43:39 
Re: Capturing a function in a closure
Vassil Nikolov <vnikol  2008-07-23 00:41:34 
Re: Capturing a function in a closure
pjb@[EMAIL PROTECTED] (P  2008-07-23 08:45:17 
Re: Capturing a function in a closure
Kent M Pitman <pitman@  2008-07-22 17:00:06 
Re: Capturing a function in a closure
Vassil Nikolov <vnikol  2008-07-23 00:44:01 
Re: Capturing a function in a closure
Barry Margolin <barmar  2008-07-23 05:03:35 
Re: Capturing a function in a closure
pjb@[EMAIL PROTECTED] (P  2008-07-23 11:38:17 
Re: Capturing a function in a closure
Vassil Nikolov <vnikol  2008-07-23 23:38:42 
Re: Capturing a function in a closure
Kaz Kylheku <kkylheku@  2008-07-24 19:12:41 
Re: Capturing a function in a closure
Kent M Pitman <pitman@  2008-07-24 19:37:56 
Re: Capturing a function in a closure
Kent M Pitman <pitman@  2008-07-24 19:26:00 
Re: Capturing a function in a closure
Kaz Kylheku <kkylheku@  2008-07-24 19:08:23 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Fri Oct 10 19:57:00 CDT 2008.