# [R6RS] [r6rs-discuss] Errors in 9.1

R. Kent Dybvig dyb at cs.indiana.edu
Tue Jun 26 23:18:56 EDT 2007

I've moved this to the editors (public) mailing list.  I agree with
Andre that this is confusing and should be fixed, although I didn't
realize it was confusing until he tripped over it.

I suggest that base.tex contain "proto" entries for each of the auxiliary
keywords exported by the base library, something like this for unquote
and unquote-splicing:

\begin{entry}{
\proto{unquote}{ \hyper{expression} \dotsfoo}{\exprtype}}
\proto{unquote-splicing}{ \hyper{expression} \dotsfoo}{\exprtype}}

These forms may appear only within a {\cf quasiquote} form.
It is a syntax violation for either to appear in any other expression
context.
\end{entry}

or perhaps better:

\begin{entry}{
\pproto{unquote}{\literaltype}}
\pproto{unquote-splicing}{\literaltype}}
\mainschindex{unquote}\mainschindex{unquote}

These keywords may appear only within a {\cf quasiquote} form.
It is a syntax violation for either to appear in any other expression
context.
\end{entry}

where \literaltype is a new marker that identifies how these things as
literals or (my preference) auxiliary keywords.

I don't know if I'm using pproto correctly, but I'm sure Mike can
correct it.

In addition to unquote and unquote-splicing, we'd need entries for
else, =>, ..., and _.

The syntax-case library would need to have similar entries for unsyntax
and unsyntax-splicing, and the records library would need to have similar
entries for the various auxiliary keywords of the define-record-type
form.

We can then remove the offending statement from Section 9.1.

Thoughts?

Kent

--------

> > On 6/26/07, AndrevanTonder <andre at het.brown.edu> wrote:
> >> I think the line
> >>
> >>    A reference to any of these identifiers out of place
> >>    is a syntax violation.
> >>
> >> was intended to be
> >>
> >>    A reference to any of these identifiers out of *phase*
> >>    is a syntax violation.
> >
> > The "out of place" text is taken from the response to formal comment #164:
> >
> >
> > There it is made clear that "out of place" means using a literal
> > keyword in an expression context.
>
> In fact, it is questionable if this comment even belongs in 9.1, which talks
> about export phases.  I think the sense of the formal comment response may
> have been lost between the formulation and execution.  In fact, the /any/ in
> "A reference to any of these identifiers out of place is a syntax violation."
> could be taken as referring to the previously mentioned syntax-rules and
> identifier-syntax as well, which were not addressed by the formal comment
> response.
>
> Also, 9.1 seems to be going through contortions to avoid mentioning that
> these are bindings.  Not referring to them as bindings is confusing, since
> it calls into question, as you noted, whether they can be shadowed.
> They should probably just be called bindings and be done with it.
>
> Andre
>
> _______________________________________________
> r6rs-discuss mailing list
> r6rs-discuss at lists.r6rs.org
> http://lists.r6rs.org/cgi-bin/mailman/listinfo/r6rs-discuss
>