5 ms·
So typeclasses in Haskell are OOP as well? Sounds like a pretty meaningless definition.
by wtetzner 6y ago
So typeclasses in Haskell are OOP as well? Sounds like a pretty meaningless definition.
- jcelerier 6y agotypeclasses are definitely oo. just because it's compile-time polymorphism doesn't make it "not oop".
- kazinator 6y agoOOP is strictly run-time polymorphism. It may be that in some instances of OOP, what calls what is deducible at compile time. That subset alone is not OOP. OOP means that an object which does not exist now can be written in the future, and loaded into code which has already been compiled and is already running now. The method calls in this existing code will correctly resolve to the method implementations in that object.
- wtetzner 6y agoThen “OOP” is an entirely meaningless definition. Where exactly are the objects in Haskell?