On May 21, 2009, at 1:32 AM, Konrad Hinsen wrote: > I can't say if there is an important difference between Haskell and > Clojure > implementation-wise.
I would be surprised if the basic idea (passing thunks instead of values) were different or could be much different. On the other hand, there are fewer ways to force a thunk evaluation in Haskell, usually through I/O, the ironically-named `seq` operator, or a strictness annotation. That might have ramifications for the implementation. At the same time, Haskell is always compiled and GHC goes to incredible lengths to optimize code; as a statically-typed, pure FP language there may be more optimizations available for it than for Clojure (but also more boilerplate and a distinction between code and data). GHC-compiled Haskell code probably outperforms Clojure code by quite a bit right now, but you're losing a fair amount of flexibility for it. And I doubt that the performance difference has much to do with laziness or how laziness is implemented in it. — Daniel Lyons http://www.storytotell.org -- Tell It! --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~----------~----~----~----~------~----~------~--~---
