diff --git a/CHANGELOG.md b/CHANGELOG.md index 4c739b02..16bdd870 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,10 +7,12 @@ Notable changes to this project are documented in this file. The format is based Breaking changes: New features: +- Export `mapCont` and `withCont` functions originally added in #70 by @parsonsmatt (#139 by @JordanMartinez) Bugfixes: Other improvements: +- Fix warnings revealed by v0.14.1 PS release (#139 by @JordanMartinez) ## [v5.0.0](https://github.com/purescript/purescript-transformers/releases/tag/v5.0.0) - 2021-02-26 diff --git a/src/Control/Comonad/Env/Trans.purs b/src/Control/Comonad/Env/Trans.purs index 2f8b2c6a..1a8d5896 100644 --- a/src/Control/Comonad/Env/Trans.purs +++ b/src/Control/Comonad/Env/Trans.purs @@ -42,10 +42,10 @@ instance extendEnvT :: Extend w => Extend (EnvT e w) where extend f (EnvT (Tuple e x)) = EnvT $ Tuple e (f <$> ((Tuple e >>> EnvT) <<= x)) instance comonadEnvT :: Comonad w => Comonad (EnvT e w) where - extract (EnvT (Tuple e x)) = extract x + extract (EnvT (Tuple _ x)) = extract x instance comonadTransEnvT :: ComonadTrans (EnvT e) where - lower (EnvT (Tuple e x)) = x + lower (EnvT (Tuple _ x)) = x instance foldableEnvT :: Foldable f => Foldable (EnvT e f) where foldl fn a (EnvT (Tuple _ x)) = foldl fn a x diff --git a/src/Control/Comonad/Store/Class.purs b/src/Control/Comonad/Store/Class.purs index fde4f130..d9bd420d 100644 --- a/src/Control/Comonad/Store/Class.purs +++ b/src/Control/Comonad/Store/Class.purs @@ -52,7 +52,7 @@ seeks :: forall s a w. ComonadStore s w => (s -> s) -> w a -> w a seeks f = peeks f <<< duplicate instance comonadStoreStoreT :: Comonad w => ComonadStore s (StoreT s w) where - pos (StoreT (Tuple f s)) = s + pos (StoreT (Tuple _ s)) = s peek s (StoreT (Tuple f _)) = extract f s instance comonadStoreEnvT :: ComonadStore s w => ComonadStore s (EnvT e w) where diff --git a/src/Control/Monad/Cont.purs b/src/Control/Monad/Cont.purs index 91b5884c..0b64fec8 100644 --- a/src/Control/Monad/Cont.purs +++ b/src/Control/Monad/Cont.purs @@ -4,6 +4,8 @@ module Control.Monad.Cont ( Cont , cont , runCont + , mapCont + , withCont , module Control.Monad.Cont.Trans , module Control.Monad.Cont.Class ) where diff --git a/src/Control/Monad/List/Trans.purs b/src/Control/Monad/List/Trans.purs index aad5bd7d..c2e62fbe 100644 --- a/src/Control/Monad/List/Trans.purs +++ b/src/Control/Monad/List/Trans.purs @@ -142,7 +142,7 @@ repeat = iterate identity -- | Take a number of elements from the front of a list. take :: forall f a. Applicative f => Int -> ListT f a -> ListT f a -take 0 fa = nil +take 0 _ = nil take n fa = stepMap f fa where f (Yield a s) = Yield a (take (n - 1) <$> s) f (Skip s) = Skip (take n <$> s) @@ -159,7 +159,7 @@ takeWhile f = stepMap g where drop :: forall f a. Applicative f => Int -> ListT f a -> ListT f a drop 0 fa = fa drop n fa = stepMap f fa where - f (Yield a s) = Skip (drop (n - 1) <$> s) + f (Yield _ s) = Skip (drop (n - 1) <$> s) f (Skip s) = Skip (drop n <$> s) f Done = Done