[plt-scheme] if without third argument

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Fri Jun 27 12:21:09 EDT 2008

At Fri, 27 Jun 2008 17:45:52 +0200, Tamas K Papp wrote:
> On Fri, Jun 27, 2008 at 09:55:50AM -0500, Robby Findler wrote:
> > You might try the pretty big language in DrScheme.
> Is it possible to get that without the GUI (just the command line)?  I
> tried but could find no options for that.
> > I'm sorry that I'm not familiar with LAML, but worst comes to worst,
> > if you're not willing to port it and its authors are also not willing
> > to port it, v372 should continue to work. I'm sorry that I don't have
> > the time myself to do that job.
> I don't see the point in porting something that conforms to a standard
> to some dialect that does not, so I am not even going to raise this to
> the author...

If the program is a "MzScheme v372" program instead of an "R5RS"
program, then you might want

  mzscheme -l mzscheme -i

The first "mzscheme" refers to an executable, and the second "mzscheme"
refers to a language (that used to be the default language of the
"mzscheme" executable). If you do that, then you get a REPL where
one-armed `if' works, since the `mzscheme' language provides that kind
of `if'. (Pairs are still immutable, though. That's the main facet of
v372 "mzscheme" that we decided not to try to preserve in 4.0.)

As Sam says, putting programs into modules is a better route all


Posted on the users mailing list.