2 ms·
In Haskell, typeclasses are special-cased and you can only have one implementation for a given type. In Scala, typeclasses arise naturally as a pattern out of m
by lmm 13y ago
In Haskell, typeclasses are special-cased and you can only have one implementation for a given type. In Scala, typeclasses arise naturally as a pattern out of more primitive building blocks, and are "just another type" that you can pass around and manipulate in ordinary ways.