composition-prelude 2.0.4.0 → 2.0.5.0
raw patch · 3 files changed
+22/−5 lines, 3 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
+ Control.Composition: (.*****) :: (g -> h) -> (a -> b -> c -> d -> e -> f -> g) -> a -> b -> c -> d -> e -> f -> h
+ Control.Composition: (.******) :: (h -> i) -> (a -> b -> c -> d -> e -> f -> g -> h) -> a -> b -> c -> d -> e -> f -> g -> i
Files
- CHANGELOG.md +5/−0
- composition-prelude.cabal +1/−1
- src/Control/Composition.hs +16/−4
CHANGELOG.md view
@@ -1,5 +1,10 @@ # composition-prelude +# 2.0.5.0+ + * Add `(.*****)` and `(.******)`.+ * Polish documentation+ # 2.0.4.0 * Fix `(.@@@)`
composition-prelude.cabal view
@@ -1,6 +1,6 @@ cabal-version: 1.18 name: composition-prelude-version: 2.0.4.0+version: 2.0.5.0 license: BSD3 license-file: LICENSE copyright: Copyright: (c) 2017-2019 Vanessa McHale
src/Control/Composition.hs view
@@ -4,6 +4,8 @@ , (.**) , (.***) , (.****)+ , (.*****)+ , (.******) -- * Precomposition , (.@) , (.@@)@@ -66,6 +68,8 @@ infixr 8 .** infixr 8 .*** infixr 8 .****+infixr 8 .*****+infixr 8 .****** infixr 8 -.* infixr 8 -.** infixr 8 -.***@@ -138,6 +142,14 @@ (.****) :: (f -> g) -> (a -> b -> c -> d -> e -> f) -> a -> b -> c -> d -> e -> g (.****) f g = \v w x y z -> f (g v w x y z) +-- | @since 2.0.5.0+(.*****) :: (g -> h) -> (a -> b -> c -> d -> e -> f -> g) -> a -> b -> c -> d -> e -> f -> h+(.*****) f g = \u v w x y z -> f (g u v w x y z)++-- | @since 2.0.5.0+(.******) :: (h -> i) -> (a -> b -> c -> d -> e -> f -> g -> h) -> a -> b -> c -> d -> e -> f -> g -> i+(.******) f g = \t u v w x y z -> f (g t u v w x y z)+ -- | A monadic version of '.*'. Compare '<=<'. -- -- As an example, one could use this to rewrite@@ -194,7 +206,7 @@ (-.**) :: (c -> d) -> (a -> b -> d -> e) -> a -> b -> c -> e (-.**) f g = \x y z -> g x y (f z)-{-# DEPRECATED (-.**) "Use .@@ instead" #-}+{-# DEPRECATED (-.**) "Use '.@@' instead" #-} -- | @since 2.0.3.0 (.@@) :: (c -> d) -> (a -> b -> d -> e) -> a -> b -> c -> e@@ -202,7 +214,7 @@ (-.***) :: (d -> e) -> (a -> b -> c -> e -> f) -> a -> b -> c -> d -> f (-.***) f g = \w x y z -> g w x y (f z)-{-# DEPRECATED (-.***) "Use .@@@ instead" #-}+{-# DEPRECATED (-.***) "Use '.@@@' instead" #-} -- | @since 2.0.3.0 (.@@@) :: (d -> e) -> (a -> b -> c -> e -> f) -> a -> b -> c -> d -> f@@ -210,7 +222,7 @@ (-.****) :: (e -> f) -> (a -> b -> c -> d -> f -> g) -> a -> b -> c -> d -> e -> g (-.****) f g = \v w x y z -> g v w x y (f z)-{-# DEPRECATED (-.****) "Use .@@@@ instead" #-}+{-# DEPRECATED (-.****) "Use '.@@@@' instead" #-} -- | @since 2.0.3.0 (.@@@@) :: (e -> f) -> (a -> b -> c -> d -> f -> g) -> a -> b -> c -> d -> e -> g@@ -219,7 +231,7 @@ -- | Backwards function composition. This is a specialization of '<&>'. (-.) :: (a -> b) -> (b -> c) -> a -> c (-.) = (<&>)-{-# DEPRECATED (-.) "Use <&> instead" #-}+{-# DEPRECATED (-.) "Use '<&>' instead" #-} {-# RULES "thread" forall f g. thread [f, g] = f . g;