Re: Tail Recursion In Erjang

2011-10-21 Thread Chouser
On Fri, Oct 21, 2011 at 10:14 AM, Stuart Sierra wrote: > Clojure does tail-call elimination for simple cases with loop/recur. This is > by far the most common case. Most other tail-recursive situations can be > represented as lazy sequences, which are another way to handle recursive > functions wi

Re: Tail Recursion In Erjang

2011-10-21 Thread Tassilo Horn
Tom Hall writes: > I'm sure the core guys have seen it but just in case others thought > the same as me here are a few links: > http://www.javalimit.com/2009/12/tail-recursion-in-erjang.html > https://github.com/trifork/erjang/wiki/How-Erjang-compiles-tail-recursion > > If someone could comment b

Re: Tail Recursion In Erjang

2011-10-21 Thread Stuart Sierra
Clojure does tail-call elimination for simple cases with loop/recur. This is by far the most common case. Most other tail-recursive situations can be represented as lazy sequences, which are another way to handle recursive functions without consuming stack space. For the final rare cases (e.g.

Tail Recursion In Erjang

2011-10-21 Thread Tom Hall
I thought tail recursion was actually not possible on the JVM but saw a talk on the Erlang VM yesterday and Robert Virding mentioned that Erjang managed to do it. I'm sure the core guys have seen it but just in case others thought the same as me here are a few links: http://www.javalimit.com/2009/