chicken-users
[Top][All Lists]
Advanced

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

Re: [Chicken-users] bug in let-optionals in 4.5.0?


From: F. Wittenberger
Subject: Re: [Chicken-users] bug in let-optionals in 4.5.0?
Date: Mon, 05 Jul 2010 13:09:34 +0200

Am Montag, den 05.07.2010, 00:33 +0200 schrieb Alejandro Forero Cuervo: 
> I'm experimenting with my format-compiler extension.  I got past the
> limitation preventing the module system from dealing with recursively
> dependent modules

I would not call this a limitation.  IMHO a module system, which allows
mutual depending modules is a pointless as a compiler with doesn't check
syntax.  It will take you quite far, until you realize that you code has
been broken all the time.

> by moving...

but you've got *the* solution already.

> Now I'm stuck in another problem, it seems to be caused by a bug in
> let-optionals.  In Chicken 3.4.0, the following form evaluates to #f,
> as expected:
> 
>   (let-optionals '(#f) ((rest #f)) #f)

Apparently nobody uses let-optionals with a "rest"-Variable.

in chicken-syntax.scm around line 641 you find:

  ;; A private var, bound to the value auf the ARG-LIST expression
  (rest-var (r '%rest))

Change this to

  (rest-var (r '%%rest))

and you are done.

/Jerry



reply via email to

[Prev in Thread] Current Thread [Next in Thread]