packages feed

mtl 2.1.2 → 2.1.3.1

raw patch · 4 files changed

+19/−2 lines, 4 files

Files

+ CHANGELOG.markdown view
@@ -0,0 +1,7 @@+2.1.3.1+-------+* Avoid importing `Control.Monad.Instances` on GHC 7.8 to build without deprecation warnings.++2.1.3+-----+* Removed the now-irrelevant `Error` constraint from the `MonadError` instance for `Either e`.
Control/Monad/Error.hs view
@@ -1,3 +1,4 @@+{-# LANGUAGE CPP #-} {- | Module      :  Control.Monad.Error Copyright   :  (c) Michael Weber <michael.weber@post.rwth-aachen.de> 2001,@@ -54,7 +55,10 @@  import Control.Monad import Control.Monad.Fix++#if defined(__GLASGOW_HASKELL__) && __GLASGOW_HASKELL__ < 707 import Control.Monad.Instances ()+#endif  {- $customErrorExample Here is an example that demonstrates the use of a custom 'Error' data type with
Control/Monad/Error/Class.hs view
@@ -1,3 +1,4 @@+{-# LANGUAGE CPP #-} {-# LANGUAGE UndecidableInstances #-}  {- |@@ -55,7 +56,11 @@ import Control.Monad.Trans.Class (lift) import Control.Exception (IOException, catch, ioError) import Control.Monad++#if defined(__GLASGOW_HASKELL__) && __GLASGOW_HASKELL__ < 707 import Control.Monad.Instances ()+#endif+ import Data.Monoid import Prelude (Either(..), (.), IO) @@ -97,7 +102,7 @@ -- --------------------------------------------------------------------------- -- Our parameterizable error monad -instance Error e => MonadError e (Either e) where+instance MonadError e (Either e) where     throwError             = Left     Left  l `catchError` h = h l     Right r `catchError` _ = Right r
mtl.cabal view
@@ -1,5 +1,5 @@ name:         mtl-version:      2.1.2+version:      2.1.3.1 cabal-version: >= 1.6 license:      BSD3 license-file: LICENSE@@ -16,6 +16,7 @@     by Mark P Jones, in /Advanced School of Functional Programming/, 1995     (<http://web.cecs.pdx.edu/~mpj/pubs/springschool.html>). build-type: Simple+extra-source-files: CHANGELOG.markdown  source-repository head   type: git