[r6rs-discuss] [Formal] (r6rs base) must also export _ and ... at level 1

AndrevanTonder andre at het.brown.edu
Thu Jan 25 10:12:51 EST 2007

On Thu, 25 Jan 2007, R. Kent Dybvig wrote:

> A potentially bigger issue is that some of these names are common enough
> that people are likely to stomp on them by accident and be frustrated when
> define-record-type reports a syntax error for input that is apparently
> well formed.

Since imported identifiers cannot be redefined, it is impossible to stomp on 
these identifiers if they are bound in (r6rs records).  They can only be 
stomped on if they are unbound in (r6rs records).  So binding them would 
eliminate exactly the potentially large class of mysterious errors 
that you describe.  I would consider this another strong argument for binding 
them (perhaps one of the strongest so far).

> For such literals, should we consider using symbolic equivalence, e.g.,
> recognize the literal 'fields' as such even if 'fields' has some different
> binding from its binding (or non-binding) in (r6rs library)?

This is a possibility.  However, I think it would make at least some of the 
macros inexpressible using syntax-rules only, to which some might object.

> This would
> prevent us from doing some of the "useful things" above, but it might save
> more than a compensating amount of grief.  Should we do the same for else
> in case, which can appear only where it cannot be confused for an
> identifier reference?

I believe some may be confused if the else in cond is treated differently from 
the else in case.


More information about the r6rs-discuss mailing list