Haskell classes allow us:
However, there are clear overlaps with the features of
powerful module systems like Standard ML. (For example, in
some ways, class and instance declarations behave much
like signature and structure/functor definitions.)
Amongst future goals, we would hope to identify a common core
in the features of these languages, and to use this to
develop an orthogonal treatment of modules and type classes
in a new language design.
- To define extensible functions.
- To defer implementation decisions.
- To reduce coupling between different parts of a program.
- To describe useful analyses in a type inference framework.