
2 Aug
2011
2 Aug
'11
10:51 a.m.
On Tue, 2 Aug 2011, Patrick Browne wrote:
What is the difference between using a class context and deriving in data type declaration? Are there certain situations in which one or the other is preferred?
data Eq a => Set1 a = NilSet1 | ConsSet1 a (Set1 a)
Note that these contexts might get removed from the language: http://hackage.haskell.org/trac/haskell-prime/wiki/NoDatatypeContexts