Safe Haskell | None |
---|---|
Language | Haskell2010 |
- eitherIf :: Bool -> ok -> fail -> Either fail ok
- fromRight :: r -> Either l r -> r
- fromRightM :: Applicative m => m r -> Either l r -> m r
- fromLeft :: l -> Either l r -> l
- fromLeftM :: Applicative m => m l -> Either l r -> m l
- unsafeFromRight :: Either l r -> r
- unsafeFromRightM :: (Monad m, MonadFail m) => Either l r -> m r
- unsafeFromLeft :: Either l r -> l
- unsafeFromLeftM :: (Monad m, MonadFail m) => Either l r -> m l
- withRight :: (Applicative m, Mempty out) => Either l r -> (r -> m out) -> m out
- withRight_ :: Applicative m => Either l r -> (r -> m out) -> m ()
- withRightM :: (Monad m, Mempty out) => m (Either l r) -> (r -> m out) -> m out
- withRightM_ :: Monad m => m (Either l r) -> (r -> m out) -> m ()
- withLeft :: (Applicative m, Mempty out) => Either l r -> (l -> m out) -> m out
- withLeft_ :: Applicative m => Either l r -> (l -> m out) -> m ()
- withLeftM :: (Monad m, Mempty out) => m (Either l r) -> (l -> m out) -> m out
- withLeftM_ :: Monad m => m (Either l r) -> (l -> m out) -> m ()
- whenRight :: (Applicative m, Mempty out) => Either l r -> m out -> m out
- whenRight_ :: Applicative m => Either l r -> m out -> m ()
- whenRightM :: (Monad m, Mempty out) => m (Either l r) -> m out -> m out
- whenRightM_ :: Monad m => m (Either l r) -> m out -> m ()
- whenLeft :: (Applicative m, Mempty out) => Either l r -> m out -> m out
- whenLeft_ :: Applicative m => Either l r -> m out -> m ()
- whenLeftM :: (Monad m, Mempty out) => m (Either l r) -> m out -> m out
- whenLeftM_ :: Monad m => m (Either l r) -> m out -> m ()
Documentation
fromRightM :: Applicative m => m r -> Either l r -> m r Source #
fromLeftM :: Applicative m => m l -> Either l r -> m l Source #
unsafeFromRight :: Either l r -> r Source #
Warning: Do not use in production code
unsafeFromLeft :: Either l r -> l Source #
Warning: Do not use in production code
withRight_ :: Applicative m => Either l r -> (r -> m out) -> m () Source #
withRightM_ :: Monad m => m (Either l r) -> (r -> m out) -> m () Source #
withLeft_ :: Applicative m => Either l r -> (l -> m out) -> m () Source #
withLeftM_ :: Monad m => m (Either l r) -> (l -> m out) -> m () Source #
whenRight_ :: Applicative m => Either l r -> m out -> m () Source #
whenRightM_ :: Monad m => m (Either l r) -> m out -> m () Source #
whenLeft_ :: Applicative m => Either l r -> m out -> m () Source #
whenLeftM_ :: Monad m => m (Either l r) -> m out -> m () Source #