Skip to content

Commit f44a714

Browse files
committed
Remove extra import
1 parent aaa6fe6 commit f44a714

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

src/Control/Applicative.purs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ module Control.Applicative
1313
import Control.Apply (class Apply, apply, (*>), (<*), (<*>))
1414
import Control.Category ((<<<))
1515

16-
import Data.Boolean (otherwise)
1716
import Data.Functor (class Functor, map, void, ($>), (<#>), (<$), (<$>))
1817
import Data.HeytingAlgebra (not)
1918
import Data.Unit (Unit, unit)
@@ -69,14 +68,14 @@ when :: forall m. Applicative m => Boolean -> m Unit -> m Unit
6968
when true m = m
7069
when false _ = pure unit
7170

72-
-- | Perform an applicative action lazily when a condition is true.
71+
-- | Construct an applicative action when a condition is true.
7372
when' :: forall m a. Applicative m => (a -> Boolean) -> (a -> m Unit) -> a -> m Unit
7473
when' f m a = if f a then m a else pure unit
7574

7675
-- | Perform an applicative action unless a condition is true.
7776
unless :: forall m. Applicative m => Boolean -> m Unit -> m Unit
7877
unless = when <<< not
7978

80-
-- | Perform an applicative action lazily unless a condition is true.
79+
-- | Construct an applicative action unless a condition is true.
8180
unless' :: forall m a. Applicative m => (a -> Boolean) -> (a -> m Unit) -> a -> m Unit
8281
unless' = when' <<< not

src/Control/Monad.purs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ liftM1 f a = do
6262
whenM :: forall m. Monad m => m Boolean -> m Unit -> m Unit
6363
whenM mb m = ifM mb m $ pure unit
6464

65-
-- | Perform a monadic action lazily when a condition is true, where the conditional
65+
-- | Construct a monadic action when a condition is true, where the conditional
6666
-- | value is also in a monadic context.
6767
whenM' :: forall m a. Monad m => (a -> m Boolean) -> (a -> m Unit) -> a -> m Unit
6868
whenM' mb m = ifM' mb m \_ -> pure unit
@@ -72,7 +72,7 @@ whenM' mb m = ifM' mb m \_ -> pure unit
7272
unlessM :: forall m. Monad m => m Boolean -> m Unit -> m Unit
7373
unlessM mb = whenM $ not <$> mb
7474

75-
-- | Perform a monadic action lazily unless a condition is true, where the conditional
75+
-- | Construct a monadic action unless a condition is true, where the conditional
7676
-- | value is also in a monadic context.
7777
unlessM' :: forall m a. Monad m => (a -> m Boolean) -> (a -> m Unit) -> a -> m Unit
7878
unlessM' mb = whenM' \x -> mb x >>= not >>> pure

0 commit comments

Comments
 (0)