chicken-users
[Top][All Lists]
Advanced

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

Re: [Chicken-users] Fwd: eval works different in Chicken 4.7 from 3.4?


From: Matt Welland
Subject: Re: [Chicken-users] Fwd: eval works different in Chicken 4.7 from 3.4?
Date: Mon, 3 Oct 2011 19:32:21 -0700

It looks like the issue is related to my using include to load all the source files instead of (declare (unit blah)) etc.

somehow procedures from included code is not visible to the eval but if I compile as units and link it works (at least in my testcase).

Seems like broken behavior to me but serves me right for being lazy and using include instead of doing it right :)

On Mon, Oct 3, 2011 at 8:09 AM, Christian Kellermann <address@hidden> wrote:
Hi Matt!

* Matt Welland <address@hidden> [111003 16:34]:
> Oops, didn't copy chicken-users...
> ---------- Forwarded message ----------
> Thanks for taking a look Christian and yes, I did hose the cut 'n paste.
> I've modified the example to better reflect the usage and here is what I get
> with compiled code:
>
> Chicken 3.3:
> > ./test
> ((Hello 3rd one))
>
> Chicken 4.7:
> > ./test
>
> Error: unbound variable: conc
>
>         Call history:
>
>         test.scm:9: open-input-file
>         test.scm:15: port-map
>         test.scm:15: read
>         <syntax>          (list (h2 "Hello " (foo 1 2) "rd one"))
>         <syntax>          (h2 "Hello " (foo 1 2) "rd one")
>         <syntax>          (foo 1 2)
>         <eval>    (list (h2 "Hello " (foo 1 2) "rd one"))
>         <eval>    (h2 "Hello " (foo 1 2) "rd one")
>         <eval>    (foo 1 2)     <--

conc is part of the unit data-structures now, so your code should
work when you also (use data-structures). I don't know whether it
was loaded by default in chicken-3.4 or whether it got moved to
this unit. Does your code work then?

Kind regards,

Christian

--
Who can (make) the muddy water (clear)? Let it be still, and it will
gradually become clear. Who can secure the condition of rest? Let
movement go on, and the condition of rest will gradually arise.
 -- Lao Tse.


reply via email to

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