packages feed

ieee 0.2 → 0.3

raw patch · 2 files changed

+8/−3 lines, 2 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

+ Data.AEq: compareListsWith :: (a -> a -> Bool) -> [a] -> [a] -> Bool

Files

Data/AEq.hs view
@@ -114,9 +114,14 @@     (===) (a1,b1,c1,d1) (a2,b2,c2,d2) = ((===) a1 a2) && ((===) b1 b2) && ((===) c1 c2) && ((===) d1 d2)     (~==) (a1,b1,c1,d1) (a2,b2,c2,d2) = ((~==) a1 a2) && ((~==) b1 b2) && ((~==) c1 c2) && ((~==) d1 d2) +compareListsWith :: (a -> a -> Bool) -> [a] -> [a] -> Bool+compareListsWith _ [] [] = True+compareListsWith f (x:xs) (y:ys) = (f x y) && (compareListsWith f xs ys)+compareListsWith _ _ _ = False+ instance (AEq a) => AEq [a] where-    (===) xs ys = and $ zipWith (===) xs ys-    (~==) xs ys = and $ zipWith (~==) xs ys+    (===) = compareListsWith (===)+    (~==) = compareListsWith (~==)  instance (AEq a) => AEq (Maybe a) where     (===) Nothing  Nothing  = True
ieee.cabal view
@@ -1,5 +1,5 @@ name:            ieee-version:         0.2+version:         0.3 homepage:        http://stat.stanford.edu/~patperry/code/ieee synopsis:        Approximate comparisons for IEEE floating point numbers description: