[plt-scheme] module name clashes

From: Mike T. Machenry (dskippy at ccs.neu.edu)
Date: Thu Dec 12 21:11:46 EST 2002

  You could use the prefix facility in the require statement.
(require (prefix s: (lib "1.ss" "srfi")))
I think that's the proper syntax or close to it. The you
reference anything provided by the srfi as s:foo instead of just


On Thu, Dec 12, 2002 at 09:01:48PM -0500, Doug Orleans wrote:
>   For list-related administrative tasks:
>   http://list.cs.brown.edu/mailman/listinfo/plt-scheme
> I'd like to use the SRFI modules from the Schematics project, but it's
> causing me some problems because it duplicates some of the stuff in
> MzLib.  For example:
>  > (module foo (lib "plt-pretty-big-text.ss" "lang")
>       (require (lib "1.ss" "srfi")))
> STDIN::338: module: identifier already imported (from a different source) at: third in: (require (lib "1.ss" "srfi"))
> Now, I guess I could go through the two modules' `provide' statements
> and figure out all the duplicate definitions and use `all-except' in a
> `require' statement, but that seems pretty tedious (and fragile).  I
> suppose I could get rid of MzLib's "list.ss" and require all the other
> MzLib modules by hand, but again this is tedious, and what if I really
> still want something provided by MzLib's list module that isn't
> provided by SRFI 1?
> What I think I want is a form of `require' (or something else) that
> will override bindings that come from another module, rather than
> complaining about them.  In other words, I want to say that I prefer
> SRFI 1 above other modules if there are any conflicts.  Is this just
> totally incompatible with the goals of the module system design?  What
> other options do I have to deal with this problem?
> --dougo at ccs.neu.edu

Posted on the users mailing list.