[Top][All Lists]

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

Re: r6rs libraries, round three

From: Julian Graham
Subject: Re: r6rs libraries, round three
Date: Sun, 25 Oct 2009 23:53:40 -0400

Hi Andy,

> It should work now, though with hacks -- if you manipulate the
> module-public-interface directly. But perhaps some more baked in support
> would be useful.

Oh, certainly -- as I've learned over these many months, you can do
some very interesting things by working with the lower-level module
API.  And indeed, that was how I did things in my initial
implementation back in March.  But...

> Can you explain a use case a bit more? I think having trouble grasping
> why you would want to do this :)

I'm trying to write a macro to convert `library' forms into
`define-module' forms.  All of the contortions you can put your
imported symbols through in R6RS can be flattened into a form that
maps quite neatly onto define-module's #:select, but #:export and
#:reexport aren't as flexible.  Specifically, the use case is
implementing the

  (rename (<identifier1> <identifier2>) ...)

form for R6RS library export-specs.  Like you said, you can manipulate
the public interface directly -- I could, say, insert the code to do
this as part of transforming the library body -- but it would be nice
if I could leave the management of the interface entirely up to


reply via email to

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