[Haskell-cafe] 3 level hierarchy of Haskell objects

Tillmann Rendel rendel at informatik.uni-marburg.de
Thu Aug 9 14:52:22 CEST 2012


Hi,

Patrick Browne wrote:
> Haskell type classes seem to be signature only (no equations, ignoring
> default methods) so in general they provide an empty theory with no
> logical consequences.

Note that many type classes in Haskell have equations annotated as 
comments. For example, the monad laws are mentioned in the documentation 
of the Monad type class:

http://hackage.haskell.org/packages/archive/base/latest/doc/html/Prelude.html#t:Monad

In this context, see also the current thread about what equations we can 
expect to hold for Eq instances:

http://thread.gmane.org/gmane.comp.lang.haskell.cafe/99517

   Tillmann



More information about the Haskell-Cafe mailing list