[R6RS] Re: Why there are two syntactic layers

Michael Sperber sperber
Thu Jun 23 23:47:48 EDT 2005

Anton van Straaten <anton at appsolutions.com> writes:

> On the syntactic interfaces, I share some of Marc's concern about the 
> two-layer interface, unless there's some rationale for it other than 
> that of a compromise amongst the editors.  That's not a great reason to 
> have to give people when explaining features of the language.

Compromise explains the history of the two layers, but the rationale
is different:

The simple syntactic layer explains the semantics of the featureful,
fancy one.  This kind of layering abounds in R5RS, which is why
Section 7.3 contains a bunch of macros explaining derived constructs
in terms of primitive ones, and that's exactly what's going on here.
COND is also a superset of IF in terms of functionality.  Now, of
course, the syntax is different between the two, and there are good
reasons for that.  (And there are good reasons for having both.)  Is
the layering a wart in the language?  No.  LETREC and LET* are
explained in terms of LET, and so on.

On the other hand, I find it frequently annoying that I have to
twiddle the syntax when moving from COND to IF or vice versa.  That's
why we chose to make the syntax of DEFINE-SIMPLE-RECORD-TYPE and

We can certainly argue whether the price is for that too high and make
corresponding changes, or generally change the syntax if that makes
people happier.  (We can also talk about the necessity of a fancy
layer again.  But I'm not getting the sense that those who want it are
willing to give up on it.)

Cheers =8-} Mike
Friede, V?lkerverst?ndigung und ?berhaupt blabla

More information about the R6RS mailing list