Re: New to haskell: unresolved overloading question

22 Feb
2005
22 Feb
'05
7:41 a.m.
Tomasz Zielonka wrote:
Why not forget about ApproxEq for () and Bool and simply define a function?
(~=) :: (Ord a, Num a) => a -> a -> Bool x ~= y = abs (x-y) < 1
Indeed, this works best. The instance for lists is also not too important. Christian
7393
Age (days ago)
7393
Last active (days ago)
0 comments
1 participants
participants (1)
-
Christian Maeder