[R6RS] Yet another question (to Matthew I guess)

Manuel Serrano Manuel.Serrano
Mon Oct 4 08:00:48 EDT 2004


> > I know this paper. I don't think that the proposed solution solved
> > the problem I'm mentioning. I don't think that the problem is actually simple.
> 
> Okay.  Perhaps you could clarify the problem.

On the example I have previously used:

-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----
(module foo r6rs
  (provides gee)

  (if (read)
      (foo))

  (define (foo)
     (let loop ((n 1000000000000000000000000000000000000000000000))
        (if (> n 0)
            (begin
               (bar n)
               (loop (- n 1))))))

  (define (bar n)
      <whatever you want>)

  (define (gee)
      ...(foo)...))
-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----|-----

it takes a smart analyse to discover that the call to foo in gee can
be optimized...

-- 
Manuel


More information about the R6RS mailing list