guile-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Transient environment with standard functions


From: Chris Vine
Subject: Re: Transient environment with standard functions
Date: Fri, 10 Jun 2016 23:35:28 +0100

On Fri, 10 Jun 2016 14:44:43 -0400
Matthew Keeter <address@hidden> wrote:
> Thanks for the reply!
> 
> You’ll be sad to hear that I’ve solved the problem by switching to
> Racket – (make-base-namespace) creates the kind of temporary
> environment I needed, and multiple calls produce multiple independent
> namespaces.

With guile, the undocumented 'make-fresh-user-module' procedure probably
does what you want.  It constructs a new top level for the thread of
execution which calls it, which is unique as against any other top
level. Whether it is what you want depends on what you mean by an
"environment", which is not necessarily the same as a "namespace".  If
you are after a new namespace, make-fresh-user-module should do it.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]