[plt-scheme] v4 top-level based languages in DrScheme

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Mon Apr 14 11:26:32 EDT 2008

At Mon, 14 Apr 2008 08:05:50 -0500, "Robby Findler" wrote:
> On Mon, Apr 14, 2008 at 7:05 AM, Grant Rettke <grettke at acm.org> wrote:
> > >  Is there anyone out there that still uses mzscheme and/or mred in v4
> >  >  or imagines that they would?
> >
> >  For what do folks usually use the mzscheme language?
> 
> The main justification for it before was that it matched what you get
> when you start up the mzscheme binary. But now that things are much
> more module-oriented, this seems much less important (specifically, if
> your program begins with "#lang ..." then calling mzscheme on it is
> more like using the "Module" language in the v4 DrScheme).

Nevertheless, one reasonable use of the "MzScheme" language was for
interactive exploration. For example, you might want to try something
like

  (module m mzscheme
    (provide x)
    (define x 5))

  (module n mzscheme
    (require 'm)
    (display x))

  (require 'n)

and then poke at the definitions of `m' and `n' without having to copy
them to the REPL for every experiment.

To support this kind of interaction, we've added a `scheme/load'
language (just now committed to SVN). Using `scheme/load', you can
perform these kinds of experiments in the Module language:

  #lang scheme/load

  (module m mzscheme
    (provide x)
    (define x 5))

  (module n mzscheme
    (require 'm)
    (display x))

  (require 'n)



Matthew



Posted on the users mailing list.