Re: [Haskell-cafe] Optimization of recursion

2004-09-28 Thread Georg Martius
Hi, I am also looking for this kind of information in general, however I have done some investigations that answer some of you questions. I posted a question on this kind of optimisation recently [1], but it kept unanswered. On Tue, 28 Sep 2004 18:10:11 + (UTC), John Goerzen [EMAIL

Re: [Haskell-cafe] Optimization of recursion

2004-09-28 Thread Alastair Reid
1. Do Haskell interpreters/compilers perform [tail call optimization]? Georg Martius wrote: ghc does it with one of -O -O1 -O2 switches. hugs doesn't seam to do it since [2] says that foldl (\n _ - n + 1) 0 [1..10] causes a stack overflow. All Haskell compilers (including Hugs)