From luke-tierney at uiowa.edu  Mon Oct  8 16:35:52 2012
From: luke-tierney at uiowa.edu (luke-tierney at uiowa.edu)
Date: Mon, 8 Oct 2012 09:35:52 -0500
Subject: [Rd] Capturing environment associated with a promise
In-Reply-To: <CABdHhvHGm8qABh7XWeMNCA9qLUFEf1ksJaf0NDH_xhyHK=jtpw@mail.gmail.com>
References: <CABdHhvHGm8qABh7XWeMNCA9qLUFEf1ksJaf0NDH_xhyHK=jtpw@mail.gmail.com>
Message-ID: <alpine.LFD.2.02.1210080933540.1869@nokomis.stat.uiowa.edu>

Promises are an implementation detail -- we need to be able to change
them, optimize them away, etc, so there is a limit on what we want to
expose.  Allowing a query of whether a binding is delayed or not
should be OK but would want to think that through more carefully
before committing to this.

luke

On Mon, 8 Oct 2012, Hadley Wickham wrote:

> Hi all,
>
> It's possible to capture the expression associated with a promise
> (using substitute). Is there any way to capture the environment
> associated with a promise?  Similarly, is there any way to tell if
> something is a promise without accidentally evaluating it?
>
> Thanks!
>
> Hadley
>
>

-- 
Luke Tierney
Chair, Statistics and Actuarial Science
Ralph E. Wareham Professor of Mathematical Sciences
University of Iowa                  Phone:             319-335-3386
Department of Statistics and        Fax:               319-335-3017
    Actuarial Science
241 Schaeffer Hall                  email:   luke-tierney at uiowa.edu
Iowa City, IA 52242                 WWW:  http://www.stat.uiowa.edu



[Rd] Capturing environment associated with a promise
luke-tierney at uiowa.edu