Trying to create a base class from which I can derive different types. What's wrong with the following?
class (Eq a) => MyClass a
data Alpha = Alpha
instance MyClass Alpha where
Alpha == Alpha = True
I get the error:
test.hs:5:10: `==' is not a (visible) method of class `MyClass'
Failed, modules loaded: none.