On Mon, Jan 7, 2013 at 3:56 AM, Peter Bex <[email protected]> wrote:

> On Sun, Jan 06, 2013 at 12:37:18PM -0500, John Cowan wrote:
> > Peter Bex scripsit:
> > > I think trying to catch these things is misguided.  It's fine if an
> > > implementation like Racket does this to guide students, but seasoned
> > > Scheme programmers don't need this kind of hand-holding.
> >
> > On the contrary.  The whole point of binding them by default is so that
> > they can safely be rebound and used as auxiliary keywords by other
> macros.
> > If they are left unbound, they are inherently non-hygienic.
>
> Isn't that by definition the case with aux-keywords in syntax-rules?
> Adding them to the default environment for this reason seems rather
> contrived, unless you go all the way and remove aux-keywords from
> syntax-rules altogether.  You can't have your pie and eat it too.
>
> Also, I'm not sure if this is R5RS-compatible.  The second form in the
> following returns 1 in Chibi, Chicken, Gambit, MIT Scheme and Gauche:
>
> (define else #f)
> (cond (else 1))
>

Note this is very deliberate on Chibi's part.  It's hygiene algorithm
would not match this by default, but it goes through extra effort to
make this work because the whole concept of auxiliary keywords
is broken.  Notably, it's otherwise impossible for library A to use
macros from unrelated libraries B and C which happen to have
chosen the same keyword.

There is a compile-time option to disable this feature in Chibi.

-- 
Alex
_______________________________________________
Scheme-reports mailing list
[email protected]
http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports

Reply via email to