Gregory Collins wrote:
Tom Davie
writes: On 10/31/09, Magicloud Magiclouds
wrote: After all, I never think OO as an oppsite way to all other things. The idea is so general that if you say I cannot use it in Haskell at all, that would make me feel weird. The only difference between languages is, some are easy to be in OO style, some are not.
Wow, someone drank the cool aid!
Doing OO-style programming in Haskell is difficult and unnatural, it's true (although technically speaking it is possible). That said, nobody's yet to present a convincing argument to me why Java gets a free pass for lacking closures and typeclasses.
G.
Because most programmers have never heard of closures and typeclasses, and thus have no idea how useful they are? :-( BTW using existential types in Haskell you can mimic OO to a pretty decent degree, at least as far as interfaces are concerned. Mike