This is the mail archive of the
kawa@sourceware.org
mailing list for the Kawa project.
Re: kawa module experience?
- From: Felix Klock <felix_klock_ii at mac dot com>
- To: dominique dot boucher at nuecho dot ad
- Cc: "'Per Bothner'" <per at bothner dot com>, kawa at sourceware dot org
- Date: Thu, 1 Dec 2005 22:32:20 -0500
- Subject: Re: kawa module experience?
- References: <20051201235532.LCYA16677.simmts7-srv.bellnexxia.net@Forman>
Dominque-
On Dec 1, 2005, at 6:57 PM, Dominique Boucher wrote:
2. Regarding the proposed library facility, I do not see problems
with the
proposed approach per se. The only missing part (maybe I have not
read the
SRFI carefully enough) is the ability to "include" source code from
another
file. This could solve many problems w.r.t. interactive/incremental
development.
The usual problem with libraries is that exported bindings cannot
be mutated
outside the library/module itself. This severely limits our ability to
change the definition of a function interactively. You have to
modify the
library and reload it, usually loosing all state information
(sometimes,
libraries are stateful), making debugging a nightmare.
There are work-arounds for this problem that are actually pretty
straight-forward, for a sufficiently expressive macro/module system.
In particular, MzScheme does not allow you to SET! identifiers
provided via a module, *unless* the module developer plans ahead to
provide such functionality. But the developer can take advantage of
set!-transformers in the macro system to get the desired effect.
For discussion (in the context of MzScheme), see the following:
http://schemecookbook.org/view/Cookbook/ProvidingSetBangableIds
(I do believe there are reasons to have an INCLUDE facility. But I
think there are better ways to get the effect you desire, such as the
one described at the schemecookbook entry above.)
-Felix