RE: [Haskell-cafe] Adding Ord constraint to instance Monad Set?

31 Mar
2004
31 Mar
'04
7:03 a.m.
But that is already used for existential datatypes: data Test = forall a . Num a => Test a Maybe that lack of forall is enough to distinguish the two though. Your example would currently be written: data (Ord a,Num b) => Either a b = Left a | Right b I dont have any problem with this, just remember these are constraints on function arguments... It my superficially look like a class system, but in reality it is more like a constraint based programming language (for example Prolog) at the type level... Regards, Keean.
7724
Age (days ago)
7724
Last active (days ago)
0 comments
1 participants
participants (1)
-
MR K P SCHUPKE