Re:Object Oriented Programming is Inherently Harmful
by Ixiaus on Sunday November 30, 2014 @11:33AM
(#8677176)
Monads, modules, and type classes (the bare essentials) make me never want to go back to Object Oriented Programming. That's not to mention all of the really clean and elegant software now blossoming in the Haskell community (Lens, Applicatives, Monoids, GADTS, pipes, etc...)
[ Parent
| on HN ]
Re:Object Oriented Programming is Inherently Harmful
by noblethrasher on Sunday November 30, 2014 @12:25PM
(#8677343)
So far, it seems that a well-designed OO language can get you closer to the best of both worlds than if you start from ML-style functional languages.
Consider that C# let's you have all three of your essentials:
It doesn't have higher-kinded types, but it does have monad comprehensions (LINQ + SelectMany)… the special syntax is nice but not necessary.
It has type classes in the form of implicit conversions.
It has modules in the form of static classes.
C# even lets you do Smalltalk-style OO without too much fuss.
The biggest problem with C# and pethaps OO in general is the lack of intellectual curiosity.