[racket] Bug in srfi-42
Thanks for the report, and thanks to Jens Axel for providing a repair
for the next version.
At Fri, 9 Jan 2015 15:53:18 -0800, William James wrote:
> Racket bug:
>
> Welcome to Racket v6.1.1.
> > (require srfi/42)
> > (list-ec (: n 2 8) (if (odd? n)) n)
> '(3 5 7)
> > (first-ec #f (: n 2 8) (if (odd? n)) n)
> stdin::80: :until: expected <generator> in
> in: (if (odd? n))
> context...:
> C:\Program Files\Racket\share\pkgs\srfi-lib\srfi\42\expansion.scm:68:2:
> gener
> ator->loop
> C:\Program Files\Racket\share\pkgs\srfi-lib\srfi\42\expansion.scm:127:7
> C:\Program Files\Racket\collects\racket\private\misc.rkt:87:7
>
> The output should be
> 3
>
> Gauche Scheme handles this correctly:
>
> gosh> (use srfi-42)
> #<undef>
> gosh> (first-ec #f (: n 2 8) (if (odd? n)) n)
> 3
>
>
>
> ____________________
> Racket Users list:
> http://lists.racket-lang.org/users