[plt-scheme] question about "module: initial import not well formed"

From: Rohan Drape (rohan.drape at gmail.com)
Date: Mon Mar 17 19:31:01 EDT 2008

On Tue, Mar 18, 2008 at 12:20 AM, Matthew Flatt <mflatt at cs.utah.edu> wrote:
> At Mon, 17 Mar 2008 23:15:09 +1100, Rohan Drape wrote:
>  > I am trying to open a module with a minimal number
>  > of bindings, and reading "The require-spec must be
>  > as for require" at:
>  >
>  >   http://docs.plt-scheme.org/reference/module.html
>
>  That's a bug in the docs. It should be a `module-path', not a
>  `require-spec'.

thanks, however i must be being slow &
i can't see how to write this.  i am wanting
something like the below r6rs (which works
in ikarus at least)

(library x
 (export ...)
 (import (only (rnrs) define lambda ...))
 ...)

is there an 'empty' module (scheme/base was
the most minimal 'public' variant i could locate)
so that we can write:

(module x empty
  (require (only-in scheme/base define lambda ...)
  ...)

or do i need to make a separate 'core' module?
i tried this as:

(module core scheme/base
  (provide define lambda ...))

(module x core
  ...)

but using x get a "module: no #%module-begin
binding in the module's language" error.

i thought it might need to be:

(module core scheme/base
  (provide (only-out scheme/base define lambda ...)))

however only-out doesn't exist.

thanks,
rohan


Posted on the users mailing list.