Questions for Geiser

Per Bothner per@bothner.com
Tue Apr 7 18:43:00 GMT 2015



On 04/07/2015 12:58 AM, Helmut Eller wrote:
> On Mon, Apr 06 2015, Per Bothner wrote:
>
>> On 04/06/2015 10:23 PM, Dan Leslie wrote:

>>> 3. Geiser is very module-centric, and supports behaviours wherein its
>>> aware of the R7RS-library or implementation-specific module in which a
>>> symbol lays and will rebind it appropriately when a relevant region or
>>> other is evaluated. What tools does Kawa provide for, say, declaring the
>>> library/module/namespace in which a block is to be evaluated?
>>
>> Kawa does support R7RS eval and load, where you can specify an
>> environment to use,
>
> I think what Dan needs/wants is something like
>
>   (eval '(define (my-function x) ...) (environment '(my own module)))
>
> but Kawa doesn't support this.

Kawa does support (eval '(....) (environment '(my own module)), which satisfies
the need for "declaring the library/module/namespace in which a block
is to be evaluated" as I understand the question.

However, you're right in that eval-ing a define will only work for the
interaction-environment.  That is as specified by r7rs.

> Correct me if I'm wrong, but I think once a module is defined it can't
> be changed because it's essentially compiled down to a JVM class.

Right.  We'd like to support some patching/re-definition of exiting modules;
it's likely the best way to do that is a combination of automatic re-compilation
with some extra indirection.

-- 
	--Per Bothner
per@bothner.com   http://per.bothner.com/



More information about the Kawa mailing list