apparent bug in sample implementation of SRFI 148 William D Clinger (18 Jul 2017 17:17 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (18 Jul 2017 19:01 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (18 Jul 2017 20:53 UTC)
Re: apparent bug in sample implementation of SRFI 148 William D Clinger (18 Jul 2017 23:33 UTC)
Re: apparent bug in sample implementation of SRFI 148 William D Clinger (19 Jul 2017 12:36 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (19 Jul 2017 13:41 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (19 Jul 2017 14:09 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (19 Jul 2017 14:27 UTC)
Re: apparent bug in sample implementation of SRFI 148 William D Clinger (19 Jul 2017 15:42 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (19 Jul 2017 17:34 UTC)
Re: apparent bug in sample implementation of SRFI 148 William D Clinger (19 Jul 2017 20:31 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (19 Jul 2017 21:07 UTC)
Re: apparent bug in sample implementation of SRFI 148 William D Clinger (20 Jul 2017 01:22 UTC)
Re: apparent bug in sample implementation of SRFI 148 William D Clinger (20 Jul 2017 01:37 UTC)
(missing)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (20 Jul 2017 08:01 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (20 Jul 2017 12:53 UTC)
Re: apparent bug in sample implementation of SRFI 148 Al Petrofsky (20 Jul 2017 23:06 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (21 Jul 2017 08:16 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (21 Jul 2017 13:13 UTC)
Re: apparent bug in sample implementation of SRFI 148 Alex Shinn (22 Jul 2017 10:53 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (22 Jul 2017 10:59 UTC)
Re: apparent bug in sample implementation of SRFI 148 Alex Shinn (22 Jul 2017 11:11 UTC)
Re: apparent bug in sample implementation of SRFI 148 Marc Nieper-Wißkirchen (20 Jul 2017 05:44 UTC)
Re: apparent bug in sample implementation of SRFI 148 Takashi Kato (20 Jul 2017 06:48 UTC)

Re: apparent bug in sample implementation of SRFI 148 William D Clinger 20 Jul 2017 01:37 UTC

The mystery may not be so mysterious after all.

Marc Nieper-Wißkirchen wrote:

> I tried the following code at the repl:

(define-syntax foo
  (syntax-rules ()
    ((foo bar x)
     (define-syntax bar
       (syntax-rules (x)
         ((bar c) 'matched)
         ((bar z) 'unmatched))))))

(foo bar c)
(bar q)

> Chez, Chibi, Racket (R6RS), Larceny (R7R6, version from yesterday) all
> evaluate the last expression to matched.

I should have tested that myself.  Chibi and Sagittarius are returning
`unmatched` for me:

% chibi-scheme -V
chibi-scheme 0.7.3 "nitrogen" (chibi r7rs ...)
% chibi-scheme
>
(define-syntax foo
  (syntax-rules ()
    ((foo bar x)
     (define-syntax bar
       (syntax-rules (x)
         ((bar c) 'matched)
         ((bar z) 'unmatched))))))
> (foo bar c)
> (bar q)
unmatched

% sagittarius --version
Sagittarius scheme shell, version 0.8.4 (x86_64-pc-linux)
% sagittarius -r7
sash[r7rs]>
(define-syntax foo
  (syntax-rules ()
    ((foo bar x)
     (define-syntax bar
       (syntax-rules (x)
         ((bar c) 'matched)
         ((bar z) 'unmatched))))))
#<unspecified>
sash[r7rs]> (foo bar c)
#<unspecified>
sash[r7rs]> (bar q)
unmatched

Kawa v2.4 also returns `unmatched`.  Petite Chez returns `matched`,
however.

Will