Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
Documentation
class ErrorContextM m => CollectErrorsM m where Source #
collectAllM :: Foldable f => f (m a) -> m [a] Source #
collectAnyM :: Foldable f => f (m a) -> m [a] Source #
collectFirstM :: Foldable f => f (m a) -> m a Source #
Instances
Monad m => CollectErrorsM (TrackedErrorsT m) Source # | |
Defined in Base.TrackedErrors collectAllM :: Foldable f => f (TrackedErrorsT m a) -> TrackedErrorsT m [a] Source # collectAnyM :: Foldable f => f (TrackedErrorsT m a) -> TrackedErrorsT m [a] Source # collectFirstM :: Foldable f => f (TrackedErrorsT m a) -> TrackedErrorsT m a Source # |
class (Monad m, MonadFail m) => ErrorContextM m where Source #
compilerErrorM :: String -> m a Source #
withContextM :: m a -> String -> m a Source #
summarizeErrorsM :: m a -> String -> m a Source #
compilerWarningM :: String -> m () Source #
compilerBackgroundM :: String -> m () Source #
resetBackgroundM :: m a -> m a Source #
Instances
class MonadTrans t => ErrorContextT t where Source #
isCompilerErrorT :: (Monad m, ErrorContextM (t m)) => t m a -> m Bool Source #
isCompilerSuccessT :: (Monad m, ErrorContextM (t m)) => t m a -> m Bool Source #
ifElseSuccessT :: (Monad m, ErrorContextM (t m)) => t m a -> m () -> m () -> t m a Source #
Instances
ErrorContextT TrackedErrorsT Source # | |
Defined in Base.TrackedErrors isCompilerErrorT :: (Monad m, ErrorContextM (TrackedErrorsT m)) => TrackedErrorsT m a -> m Bool Source # isCompilerSuccessT :: (Monad m, ErrorContextM (TrackedErrorsT m)) => TrackedErrorsT m a -> m Bool Source # ifElseSuccessT :: (Monad m, ErrorContextM (TrackedErrorsT m)) => TrackedErrorsT m a -> m () -> m () -> TrackedErrorsT m a Source # |
(<??) :: ErrorContextM m => m a -> String -> m a infixl 1 Source #
(??>) :: ErrorContextM m => String -> m a -> m a infixr 1 Source #
(<!!) :: ErrorContextM m => m a -> String -> m a infixl 1 Source #
(!!>) :: ErrorContextM m => String -> m a -> m a infixr 1 Source #
collectAllM_ :: (Foldable f, CollectErrorsM m) => f (m a) -> m () Source #
collectFirstM_ :: (Foldable f, CollectErrorsM m) => f (m a) -> m () Source #
emptyErrorM :: CollectErrorsM m => m a Source #
errorFromIO :: (MonadIO m, ErrorContextM m) => IO a -> m a Source #
isCompilerError :: (ErrorContextT t, ErrorContextM (t Identity)) => t Identity a -> Bool Source #
isCompilerErrorM :: CollectErrorsM m => m a -> m Bool Source #
isCompilerSuccess :: (ErrorContextT t, ErrorContextM (t Identity)) => t Identity a -> Bool Source #
isCompilerSuccessM :: CollectErrorsM m => m a -> m Bool Source #
mapCompilerM :: CollectErrorsM m => (a -> m b) -> [a] -> m [b] Source #
mapCompilerM_ :: CollectErrorsM m => (a -> m b) -> [a] -> m () Source #
mapErrorsM :: CollectErrorsM m => [String] -> m a Source #