[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Scheme-reports] multiple values module



On Wed, May 25, 2011 at 10:08 AM, Andy Wingo <wingo@x> wrote:
>
> On Wed 25 May 2011 11:04, Eli Barzilay <eli@x> writes:
>
>> Chibi's problem
>
> Is probably just a bug.  I'll assume that's the case; it was a good
> catch on your part.

It was known behavior, left in place mostly because I
didn't actually care :)  Any Scheme that behaves like
Chibi in this case can be fixed with:

(define orig-call/cc call-with-current-continuation)

(define call-with-current-continuation
  (lambda (proc)
    (orig-call/cc
     (lambda (return) (proc (lambda args (return (apply values args))))))))

The actual fix in Chibi was just one line, which I
just pushed now since people are arguing about it,
and so you can now say Chibi's call/cc is 100%
R5RS compliant.

I didn't do this before because I hate MV with a
fiery passion.  I think it's a very natural and aesthetically
pleasing extension to the language that happens to
backfire, making the compiler, the runtime, and _all_
user code considerably more complex.  I originally
intended to join the WG with a primary goal of fighting
to remove MV with all my strength.  When I was made
the chair I had to give that up, because it was an
underdog goal to begin with and because I would no
longer have time.

Thus I will not go into specifics of why I think MV
is so horribly broken.

My compromise in Chibi was that I'd support MV only
if the core compiler never had to touch it.  A few
lines of Scheme in an easily replaced init file doesn't
bother me.  A single line of C or a single new type
would have been unacceptable.

-- 
Alex

_______________________________________________
Scheme-reports mailing list
Scheme-reports@x
http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports