31 Aug
2001
31 Aug
'01
9:56 a.m.
Hi, I am a newbie, so I might be making nonsense. In the following definiton: class Eq a where (==) :: a -> a -> Bool Why do we conlude that both of the "a" refer to the same type? Apparently using different types that both belonging to class Eq results in an error. For example 65 == 'a' It doesn't make much sense at first, however, how do you go by implementing multiple polymorphism? Secondly, why does Haskell distinguish between a Type and a Class? There seems to be no benefit of such approach. Thirdly, is it possible to define meta-classes in Haskell? Thanks