/usr/share/doc/libghc-exceptions-doc/html/Control-Monad-Catch-Pure.html is in libghc-exceptions-doc 0.8.3-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Control.Monad.Catch.Pure</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script src="file:///usr/share/javascript/mathjax/MathJax.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Control-Monad-Catch-Pure.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="src/Control-Monad-Catch-Pure.html">Source</a></li><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">exceptions-0.8.3: Extensible optionally-pure exceptions</p></div><div id="content"><div id="module-header"><table class="info"><tr><th valign="top">Copyright</th><td>(C) Edward Kmett 2013-2015 (c) Google Inc. 2012</td></tr><tr><th>License</th><td>BSD-style (see the file LICENSE)</td></tr><tr><th>Maintainer</th><td>Edward Kmett <ekmett@gmail.com></td></tr><tr><th>Stability</th><td>experimental</td></tr><tr><th>Portability</th><td>non-portable</td></tr><tr><th>Safe Haskell</th><td>Trustworthy</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Control.Monad.Catch.Pure</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Transformer</a></li><li><a href="#g:2">Typeclass</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module supplies a 'pure' monad transformer that can be used for
mock-testing code that throws exceptions, so long as those exceptions
are always thrown with <code><a href="Control-Monad-Catch.html#v:throwM">throwM</a></code>.</p><p>Do not mix <code><a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a></code> with <code><a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/System-IO.html#t:IO">IO</a></code>. Choose one or the other for the
bottom of your transformer stack!</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">newtype</span> <a href="#t:CatchT">CatchT</a> m a = <a href="#v:CatchT">CatchT</a> {<ul class="subs"><li><a href="#v:runCatchT">runCatchT</a> :: m (<a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Either.html#t:Either">Either</a> <a href="Control-Monad-Catch.html#t:SomeException">SomeException</a> a)</li></ul>}</li><li class="src short"><span class="keyword">type</span> <a href="#t:Catch">Catch</a> = <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Functor-Identity.html#t:Identity">Identity</a></li><li class="src short"><a href="#v:runCatch">runCatch</a> :: <a href="Control-Monad-Catch-Pure.html#t:Catch">Catch</a> a -> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Either.html#t:Either">Either</a> <a href="Control-Monad-Catch.html#t:SomeException">SomeException</a> a</li><li class="src short"><a href="#v:mapCatchT">mapCatchT</a> :: (m (<a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Either.html#t:Either">Either</a> <a href="Control-Monad-Catch.html#t:SomeException">SomeException</a> a) -> n (<a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Either.html#t:Either">Either</a> <a href="Control-Monad-Catch.html#t:SomeException">SomeException</a> b)) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> n b</li><li class="src short">module <a href="Control-Monad-Catch.html">Control.Monad.Catch</a></li></ul></div><div id="interface"><h1 id="g:1">Transformer</h1><div class="doc"><p>The <code>transformers</code>-style monad transfomer</p></div><div class="top"><p class="src"><span class="keyword">newtype</span> <a id="t:CatchT" class="def">CatchT</a> m a <a href="src/Control-Monad-Catch-Pure.html#CatchT" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></p><div class="doc"><p>Add <code><a href="Control-Monad-Catch.html#t:Exception">Exception</a></code> handling abilities to a <code><a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a></code>.</p><p>This should <em>never</em> be used in combination with <code><a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/System-IO.html#t:IO">IO</a></code>. Think of <code><a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a></code>
as an alternative base monad for use with mocking code that solely throws
exceptions via <code><a href="Control-Monad-Catch.html#v:throwM">throwM</a></code>.</p><p>Note: that <code><a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/System-IO.html#t:IO">IO</a></code> monad has these abilities already, so stacking <code><a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a></code> on top
of it does not add any value and can possibly be confusing:</p><pre class="screen"><code class="prompt">>>> </code><strong class="userinput"><code>(error "Hello!" :: IO ()) `catch` (\(e :: ErrorCall) -> liftIO $ print e)
</code></strong>Hello!
</pre><pre class="screen"><code class="prompt">>>> </code><strong class="userinput"><code>runCatchT $ (error "Hello!" :: CatchT IO ()) `catch` (\(e :: ErrorCall) -> liftIO $ print e)
</code></strong>*** Exception: Hello!
</pre><pre class="screen"><code class="prompt">>>> </code><strong class="userinput"><code>runCatchT $ (throwM (ErrorCall "Hello!") :: CatchT IO ()) `catch` (\(e :: ErrorCall) -> liftIO $ print e)
</code></strong>Hello!
</pre></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a id="v:CatchT" class="def">CatchT</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><ul><li><dfn class="src"><a id="v:runCatchT" class="def">runCatchT</a> :: m (<a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Either.html#t:Either">Either</a> <a href="Control-Monad-Catch.html#t:SomeException">SomeException</a> a)</dfn><div class="doc empty"> </div></li></ul></div></td></tr></table></div><div class="subs instances"><p id="control.i:CatchT" class="caption collapser" onclick="toggleSection('i:CatchT')">Instances</p><div id="section.i:CatchT" class="show"><table><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:MonadTrans:1" class="instance expander" onclick="toggleSection('i:id:CatchT:MonadTrans:1')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/transformers-0.5.2.0/Control-Monad-Trans-Class.html#t:MonadTrans">MonadTrans</a> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a></span> <a href="src/Control-Monad-Catch-Pure.html#line-139" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:MonadTrans:1" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:lift">lift</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m => m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:lift" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:MonadRWS:2" class="instance expander" onclick="toggleSection('i:id:CatchT:MonadRWS:2')"></span> <a href="file:///usr/share/doc/libghc-mtl-doc/html/Control-Monad-RWS-Class.html#t:MonadRWS">MonadRWS</a> r w s m => <a href="file:///usr/share/doc/libghc-mtl-doc/html/Control-Monad-RWS-Class.html#t:MonadRWS">MonadRWS</a> r w s (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-188" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:MonadRWS:2" class="inst-details hide"></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:MonadReader:3" class="instance expander" onclick="toggleSection('i:id:CatchT:MonadReader:3')"></span> <a href="file:///usr/share/doc/libghc-mtl-doc/html/Control-Monad-Reader-Class.html#t:MonadReader">MonadReader</a> e m => <a href="file:///usr/share/doc/libghc-mtl-doc/html/Control-Monad-Reader-Class.html#t:MonadReader">MonadReader</a> e (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-170" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:MonadReader:3" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:ask">ask</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m e <a href="#v:ask" class="selflink">#</a></p><p class="src"><a href="#v:local">local</a> :: (e -> e) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:local" class="selflink">#</a></p><p class="src"><a href="#v:reader">reader</a> :: (e -> a) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:reader" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:MonadState:4" class="instance expander" onclick="toggleSection('i:id:CatchT:MonadState:4')"></span> <a href="file:///usr/share/doc/libghc-mtl-doc/html/Control-Monad-State-Class.html#t:MonadState">MonadState</a> s m => <a href="file:///usr/share/doc/libghc-mtl-doc/html/Control-Monad-State-Class.html#t:MonadState">MonadState</a> s (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-163" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:MonadState:4" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:get">get</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m s <a href="#v:get" class="selflink">#</a></p><p class="src"><a href="#v:put">put</a> :: s -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m () <a href="#v:put" class="selflink">#</a></p><p class="src"><a href="#v:state">state</a> :: (s -> (a, s)) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:state" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:MonadWriter:5" class="instance expander" onclick="toggleSection('i:id:CatchT:MonadWriter:5')"></span> <a href="file:///usr/share/doc/libghc-mtl-doc/html/Control-Monad-Writer-Class.html#t:MonadWriter">MonadWriter</a> w m => <a href="file:///usr/share/doc/libghc-mtl-doc/html/Control-Monad-Writer-Class.html#t:MonadWriter">MonadWriter</a> w (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-174" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:MonadWriter:5" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:writer">writer</a> :: (a, w) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:writer" class="selflink">#</a></p><p class="src"><a href="#v:tell">tell</a> :: w -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m () <a href="#v:tell" class="selflink">#</a></p><p class="src"><a href="#v:listen">listen</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m (a, w) <a href="#v:listen" class="selflink">#</a></p><p class="src"><a href="#v:pass">pass</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m (a, w -> w) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:pass" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:Monad:6" class="instance expander" onclick="toggleSection('i:id:CatchT:Monad:6')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m => <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-107" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:Monad:6" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:-62--62--61-">(>>=)</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> (a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b <a href="#v:-62--62--61-" class="selflink">#</a></p><p class="src"><a href="#v:-62--62-">(>>)</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b <a href="#v:-62--62-" class="selflink">#</a></p><p class="src"><a href="#v:return">return</a> :: a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:return" class="selflink">#</a></p><p class="src"><a href="#v:fail">fail</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-String.html#t:String">String</a> -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:fail" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:Functor:7" class="instance expander" onclick="toggleSection('i:id:CatchT:Functor:7')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m => <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Functor.html#t:Functor">Functor</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-100" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:Functor:7" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:fmap">fmap</a> :: (a -> b) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b <a href="#v:fmap" class="selflink">#</a></p><p class="src"><a href="#v:-60--36-">(<$)</a> :: a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:-60--36-" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:MonadFix:8" class="instance expander" onclick="toggleSection('i:id:CatchT:MonadFix:8')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad-Fix.html#t:MonadFix">MonadFix</a> m => <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad-Fix.html#t:MonadFix">MonadFix</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-114" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:MonadFix:8" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:mfix">mfix</a> :: (a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:mfix" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:Applicative:9" class="instance expander" onclick="toggleSection('i:id:CatchT:Applicative:9')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m => <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Applicative.html#t:Applicative">Applicative</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-103" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:Applicative:9" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:pure">pure</a> :: a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:pure" class="selflink">#</a></p><p class="src"><a href="#v:-60--42--62-">(<*>)</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m (a -> b) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b <a href="#v:-60--42--62-" class="selflink">#</a></p><p class="src"><a href="#v:-42--62-">(*>)</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b <a href="#v:-42--62-" class="selflink">#</a></p><p class="src"><a href="#v:-60--42-">(<*)</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:-60--42-" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:Foldable:10" class="instance expander" onclick="toggleSection('i:id:CatchT:Foldable:10')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Foldable.html#t:Foldable">Foldable</a> m => <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Foldable.html#t:Foldable">Foldable</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-119" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:Foldable:10" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:fold">fold</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Monoid.html#t:Monoid">Monoid</a> m => <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m m -> m <a href="#v:fold" class="selflink">#</a></p><p class="src"><a href="#v:foldMap">foldMap</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Monoid.html#t:Monoid">Monoid</a> m => (a -> m) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> m <a href="#v:foldMap" class="selflink">#</a></p><p class="src"><a href="#v:foldr">foldr</a> :: (a -> b -> b) -> b -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> b <a href="#v:foldr" class="selflink">#</a></p><p class="src"><a href="#v:foldr-39-">foldr'</a> :: (a -> b -> b) -> b -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> b <a href="#v:foldr-39-" class="selflink">#</a></p><p class="src"><a href="#v:foldl">foldl</a> :: (b -> a -> b) -> b -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> b <a href="#v:foldl" class="selflink">#</a></p><p class="src"><a href="#v:foldl-39-">foldl'</a> :: (b -> a -> b) -> b -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> b <a href="#v:foldl-39-" class="selflink">#</a></p><p class="src"><a href="#v:foldr1">foldr1</a> :: (a -> a -> a) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> a <a href="#v:foldr1" class="selflink">#</a></p><p class="src"><a href="#v:foldl1">foldl1</a> :: (a -> a -> a) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> a <a href="#v:foldl1" class="selflink">#</a></p><p class="src"><a href="#v:toList">toList</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> [a] <a href="#v:toList" class="selflink">#</a></p><p class="src"><a href="#v:null">null</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:null" class="selflink">#</a></p><p class="src"><a href="#v:length">length</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Int.html#t:Int">Int</a> <a href="#v:length" class="selflink">#</a></p><p class="src"><a href="#v:elem">elem</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Eq.html#t:Eq">Eq</a> a => a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="#v:elem" class="selflink">#</a></p><p class="src"><a href="#v:maximum">maximum</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Ord.html#t:Ord">Ord</a> a => <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> a <a href="#v:maximum" class="selflink">#</a></p><p class="src"><a href="#v:minimum">minimum</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Ord.html#t:Ord">Ord</a> a => <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> a <a href="#v:minimum" class="selflink">#</a></p><p class="src"><a href="#v:sum">sum</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Prelude.html#t:Num">Num</a> a => <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> a <a href="#v:sum" class="selflink">#</a></p><p class="src"><a href="#v:product">product</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Prelude.html#t:Num">Num</a> a => <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> a <a href="#v:product" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:Traversable:11" class="instance expander" onclick="toggleSection('i:id:CatchT:Traversable:11')"></span> (<a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m, <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Traversable.html#t:Traversable">Traversable</a> m) => <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Traversable.html#t:Traversable">Traversable</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-124" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:Traversable:11" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:traverse">traverse</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Applicative.html#t:Applicative">Applicative</a> f => (a -> f b) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> f (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b) <a href="#v:traverse" class="selflink">#</a></p><p class="src"><a href="#v:sequenceA">sequenceA</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Applicative.html#t:Applicative">Applicative</a> f => <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m (f a) -> f (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a) <a href="#v:sequenceA" class="selflink">#</a></p><p class="src"><a href="#v:mapM">mapM</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m => (a -> m b) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> m (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b) <a href="#v:mapM" class="selflink">#</a></p><p class="src"><a href="#v:sequence">sequence</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m => <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m (m a) -> m (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a) <a href="#v:sequence" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:MonadIO:12" class="instance expander" onclick="toggleSection('i:id:CatchT:MonadIO:12')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad-IO-Class.html#t:MonadIO">MonadIO</a> m => <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad-IO-Class.html#t:MonadIO">MonadIO</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-144" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:MonadIO:12" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:liftIO">liftIO</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/System-IO.html#t:IO">IO</a> a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:liftIO" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:Alternative:13" class="instance expander" onclick="toggleSection('i:id:CatchT:Alternative:13')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m => <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Applicative.html#t:Alternative">Alternative</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-129" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:Alternative:13" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:empty">empty</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:empty" class="selflink">#</a></p><p class="src"><a href="#v:-60--124--62-">(<|>)</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:-60--124--62-" class="selflink">#</a></p><p class="src"><a href="#v:some">some</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m [a] <a href="#v:some" class="selflink">#</a></p><p class="src"><a href="#v:many">many</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m [a] <a href="#v:many" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:MonadPlus:14" class="instance expander" onclick="toggleSection('i:id:CatchT:MonadPlus:14')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m => <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:MonadPlus">MonadPlus</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-133" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:MonadPlus:14" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:mzero">mzero</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:mzero" class="selflink">#</a></p><p class="src"><a href="#v:mplus">mplus</a> :: <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="#v:mplus" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:MonadMask:15" class="instance expander" onclick="toggleSection('i:id:CatchT:MonadMask:15')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m => <a href="Control-Monad-Catch.html#t:MonadMask">MonadMask</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-159" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc"><p>Note: This instance is only valid if the underlying monad has a single
exit point!</p></td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:MonadMask:15" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:mask">mask</a> :: ((<span class="keyword">forall</span> a. <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b <a href="src/Control-Monad-Catch.html#mask" class="link">Source</a> <a href="#v:mask" class="selflink">#</a></p><p class="src"><a href="#v:uninterruptibleMask">uninterruptibleMask</a> :: ((<span class="keyword">forall</span> a. <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m b <a href="src/Control-Monad-Catch.html#uninterruptibleMask" class="link">Source</a> <a href="#v:uninterruptibleMask" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:MonadCatch:16" class="instance expander" onclick="toggleSection('i:id:CatchT:MonadCatch:16')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m => <a href="Control-Monad-Catch.html#t:MonadCatch">MonadCatch</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-151" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:MonadCatch:16" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:catch">catch</a> :: <a href="Control-Monad-Catch.html#t:Exception">Exception</a> e => <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> (e -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="src/Control-Monad-Catch.html#catch" class="link">Source</a> <a href="#v:catch" class="selflink">#</a></p></div></div></td></tr><tr><td class="src clearfix"><span class="inst-left"><span id="control.i:id:CatchT:MonadThrow:17" class="instance expander" onclick="toggleSection('i:id:CatchT:MonadThrow:17')"></span> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Control-Monad.html#t:Monad">Monad</a> m => <a href="Control-Monad-Catch.html#t:MonadThrow">MonadThrow</a> (<a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m)</span> <a href="src/Control-Monad-Catch-Pure.html#line-149" class="link">Source</a> <a href="#t:CatchT" class="selflink">#</a></td><td class="doc empty"> </td></tr><tr><td colspan="2"><div id="section.i:id:CatchT:MonadThrow:17" class="inst-details hide"><div class="subs methods"><p class="caption">Methods</p><p class="src"><a href="#v:throwM">throwM</a> :: <a href="Control-Monad-Catch.html#t:Exception">Exception</a> e => e -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a <a href="src/Control-Monad-Catch.html#throwM" class="link">Source</a> <a href="#v:throwM" class="selflink">#</a></p></div></div></td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a id="t:Catch" class="def">Catch</a> = <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Functor-Identity.html#t:Identity">Identity</a> <a href="src/Control-Monad-Catch-Pure.html#Catch" class="link">Source</a> <a href="#t:Catch" class="selflink">#</a></p></div><div class="top"><p class="src"><a id="v:runCatch" class="def">runCatch</a> :: <a href="Control-Monad-Catch-Pure.html#t:Catch">Catch</a> a -> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Either.html#t:Either">Either</a> <a href="Control-Monad-Catch.html#t:SomeException">SomeException</a> a <a href="src/Control-Monad-Catch-Pure.html#runCatch" class="link">Source</a> <a href="#v:runCatch" class="selflink">#</a></p></div><div class="top"><p class="src"><a id="v:mapCatchT" class="def">mapCatchT</a> :: (m (<a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Either.html#t:Either">Either</a> <a href="Control-Monad-Catch.html#t:SomeException">SomeException</a> a) -> n (<a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.1.0/Data-Either.html#t:Either">Either</a> <a href="Control-Monad-Catch.html#t:SomeException">SomeException</a> b)) -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> m a -> <a href="Control-Monad-Catch-Pure.html#t:CatchT">CatchT</a> n b <a href="src/Control-Monad-Catch-Pure.html#mapCatchT" class="link">Source</a> <a href="#v:mapCatchT" class="selflink">#</a></p><div class="doc"><p>Map the unwrapped computation using the given function.</p><pre><code><a href="Control-Monad-Catch-Pure.html#v:runCatchT">runCatchT</a></code> (<code><a href="Control-Monad-Catch-Pure.html#v:mapCatchT">mapCatchT</a></code> f m) = f (<code><a href="Control-Monad-Catch-Pure.html#v:runCatchT">runCatchT</a></code> m)</pre></div></div><h1 id="g:2">Typeclass</h1><div class="doc"><p>The mtl style typeclass</p></div><div class="top"><p class="src">module <a href="Control-Monad-Catch.html">Control.Monad.Catch</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.17.3</p></div></body></html>
|