News for hackers. Stuff that matters.
Re:Why Lisp is a Big Hack and Haskell is Doomed to Succeed (... by pekk on Sunday March 30, 2014 @07:38PM (#7498479)
How is a program correct if resource leaks cause it not to perform the intended task?
Re:Why Lisp is a Big Hack and Haskell is Doomed to Succeed (... by axman6 on Sunday March 30, 2014 @08:30PM (#7498698)
I think this is more of an implementation issue than a language issue. A haskell compiler could choose to reevaluate everything every time it's demanded, and it would run in very little space. GHC uses thunks to represent computations which haven't been run yet, which are replaced once any threads evaluates them. This can lead to space leaks, but I don't believe there's any requirement that this be how the results are evaluated. GHC chooses this evaluation strtategy because it usually results in faster code, but obviously can lead to problems if you don't know what you're doing. Like all languages, it takes experience to avoid whatever deficiency exists in your language of choice; it won't be obvious to a beginner why the naive implementation of fibonacci works for some values but overflows the stack on others, but they will eventually learn.
Re:Why Lisp is a Big Hack and Haskell is Doomed to Succeed (... by chongli on Monday March 31, 2014 @03:32AM (#7500150)
Haskell the language is concerned with proving small theorems about the program as specified by the source code. Actually running it is outside the scope of language specification; it's an implementation detail. GHC (the defacto compiler for Haskell) makes a lot of resource tradeoffs to try and achieve better performance.