chicken-users
[Top][All Lists]
Advanced

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

Re: [Chicken-users] External representation for continuations


From: Felix Winkelmann
Subject: Re: [Chicken-users] External representation for continuations
Date: Thu, 02 Sep 2004 07:27:54 +0200
User-agent: Mozilla Thunderbird 0.5 (X11/20040208)

Thomas Chust wrote:

Sorry for the stupid question, but what does CHICKEN make of an (eval (read)) in compiled code? I don't quite understand what you mean by "the C procedures are already there".

Not stupid at all. Chicken "compiles" s-exprs to be interpreted into
a closure tree, so for example:

'(+ 1 2)

is (roughly) compiled into:

(let ([l1 (lambda (env) 1)]
      [l2 (lambda (env) 2)]
      [l3 (lambda (env) +)] )
  (lambda (env)
    ((l3 env) (l1 env) (l2 env)) ) )

The actual machine code for these lambdas exsists in the eval
unit.
See also:

http://www.iro.umontreal.ca/~feeley/papers/complang87.ps.gz


I'd actually be interested in the code of the original Kali Scheme implementation (which was based on Scheme 48). But it seems to be no longer available for download...


http://fifalde.merseine.nu/~r2q2/kali-scheme-revival.html


cheers,
felix




reply via email to

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