packages feed

syb-extras 0.2.1.1 → 0.2.2

raw patch · 1 files changed

+5/−5 lines, 1 filesdep ~eqPVP: major bump suggested

API removals or changes: PVP suggests a major version bump

Dependency ranges changed: eq

API changes (from Hackage documentation)

- Data.Data.Extras: class Typeable1 f => Data1 f
+ Data.Data.Extras: class Typeable1 f => Data1 f where gfoldl1 _ z = z dataCast1_1 _ = Nothing dataCast2_1 _ = Nothing gmapT1 f x0 = unID (gfoldl1 (\ (ID c) x -> ID (c (f x))) ID x0) gmapQl1 o r f = unCONST . gfoldl1 (\ c x -> CONST $ unCONST c `o` f x) (\ _ -> CONST r) gmapQr1 o r0 f x0 = unQr (gfoldl1 (\ (Qr c) x -> Qr (\ r -> c (f x `o` r))) (const (Qr id)) x0) r0 gmapQ1 f = gmapQr1 (:) [] f gmapQi1 i f x = fromJust $ unQi $ gfoldl1 (\ (Qi i' q) a -> Qi (i' + 1) (if i == i' then Just (f a) else q)) (\ _ -> Qi 0 Nothing) x gmapM1 f = gfoldl1 (\ c x -> do { c' <- c; liftM c' (f x) }) return gmapMp1 f x = unMp (gfoldl1 k z x) >>= \ (x', b) -> if b then return x' else mzero where z g = Mp (return (g, False)) k (Mp c) y = Mp (c >>= \ (h, b) -> (f y >>= \ y' -> return (h y', True)) `mplus` return (h y, b)) gmapMo1 f x = unMp (gfoldl1 k z x) >>= \ (x', b) -> if b then return x' else mzero where z g = Mp (return (g, False)) k (Mp c) y = Mp (c >>= \ (h, b) -> if b then return (h y, b) else (f y >>= \ y' -> return (h y', True)) `mplus` return (h y, b))
- Data.Data.Extras: class Typeable2 f => Data2 f
+ Data.Data.Extras: class Typeable2 f => Data2 f where gfoldl2 _ z = z dataCast1_2 _ = Nothing dataCast2_2 _ = Nothing gmapT2 f x0 = unID (gfoldl2 (\ (ID c) x -> ID (c (f x))) ID x0) gmapQl2 o r f = unCONST . gfoldl2 (\ c x -> CONST $ unCONST c `o` f x) (\ _ -> CONST r) gmapQr2 o r0 f x0 = unQr (gfoldl2 (\ (Qr c) x -> Qr (\ r -> c (f x `o` r))) (const (Qr id)) x0) r0 gmapQ2 f = gmapQr2 (:) [] f gmapQi2 i f x = fromJust $ unQi $ gfoldl2 (\ (Qi i' q) a -> Qi (i' + 2) (if i == i' then Just (f a) else q)) (\ _ -> Qi 0 Nothing) x gmapM2 f = gfoldl2 (\ c x -> do { c' <- c; liftM c' (f x) }) return gmapMp2 f x = unMp (gfoldl2 k z x) >>= \ (x', b) -> if b then return x' else mzero where z g = Mp (return (g, False)) k (Mp c) y = Mp (c >>= \ (h, b) -> (f y >>= \ y' -> return (h y', True)) `mplus` return (h y, b)) gmapMo2 f x = unMp (gfoldl2 k z x) >>= \ (x', b) -> if b then return x' else mzero where z g = Mp (return (g, False)) k (Mp c) y = Mp (c >>= \ (h, b) -> if b then return (h y, b) else (f y >>= \ y' -> return (h y', True)) `mplus` return (h y, b))

Files

syb-extras.cabal view
@@ -1,6 +1,6 @@ name:          syb-extras category:      Polymorphism, Combinators, Generic-version:       0.2.1.1+version:       0.2.2 license:       BSD3 cabal-version: >= 1.6 license-file:  LICENSE@@ -18,14 +18,14 @@   location: git://github.com/ekmett/syb-extras.git  library-  build-depends: -    base >= 4 && < 5,+  build-depends:+    base           >= 4 && < 5,     prelude-extras >= 0.1 && < 0.3,-    eq >= 0.3.2 && <= 0.4+    eq             >= 0.3.6 && <= 0.4    extensions: CPP -  ghc-options: -Wall +  ghc-options: -Wall    exposed-modules:     Data.Data.Extras