chicken-users
[Top][All Lists]
Advanced

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

Re: [Chicken-users] Compilation issue with v4.7.0


From: Mario Domenech Goulart
Subject: Re: [Chicken-users] Compilation issue with v4.7.0
Date: Fri, 12 Aug 2011 16:42:56 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.91 (gnu/linux)

On Fri, 12 Aug 2011 16:33:25 -0400 Mario Domenech Goulart <address@hidden> 
wrote:

> On Fri, 12 Aug 2011 07:56:39 -0700 Paul Colby <address@hidden> wrote:
>
>> I tried the following file as a prelude to doing conditional
>> compilation and ran into the following snag,
>>
>> ----------------------------- example.scm -----------------------
>> (define A #t)
>> (define B 'undefined)
>> (if A
>>  (set! B 'good)
>>  (set! B 'bad))
>> (print B)
>> ------------------------------ end ----------------------------------
>>
>> running csi prints out the expected message 'good'
>> compiling using 'csc example.scm' and running the
>> executable results in 'undefined' being printed. the
>> code generated by 'csc -t example.scm' is given below.
>
> That piece of code used to work as expected when compiled by Chicken
> 4.3.0.  It seems that 37c7156da6c0b23536c031f44a7734a8c6542e84 has
> triggered the behavior you report.
>
> The following patch brings the old behavior back, but I'm not sure it is
> the right fix (probably Felix can tell):
>
> index 1e30ed4..5405645 100644
> --- a/optimizer.scm
> +++ b/optimizer.scm
> @@ -72,9 +72,7 @@
>              (set! previous (remove (lambda (p) (eq? (car p) var))
>              previous)))]
>  
>           [(if ##core#cond ##core#switch)
> -          (scan (first subs) e)
> -          (touch)
> -          (scan-each (cdr subs) e)]
> +          (scan (first subs) e) ]
>  
>           [(let)
>            (scan-each (butlast subs) e)

Forgot to mention that this patch is against the git HEAD code, not
against 4.7.0...

Best wishes.
Mario
-- 
http://parenteses.org/mario



reply via email to

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