either 3.3 → 3.4
raw patch · 3 files changed
+8/−1 lines, 3 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- CHANGELOG.markdown +4/−0
- either.cabal +1/−1
- src/Control/Monad/Trans/Either.hs +3/−0
CHANGELOG.markdown view
@@ -1,3 +1,7 @@+3.4+---+* Delegate `fail` to the underlying `Monad`, rather than `error`.+ 3.3 --- * Inverted roles between `Semigroup` and `Alt`. This let us write `Alternative` and `MonadPlus` instances that are compatible.
either.cabal view
@@ -1,6 +1,6 @@ name: either category: Control, Monads-version: 3.3+version: 3.4 license: BSD3 cabal-version: >= 1.6 license-file: LICENSE
src/Control/Monad/Trans/Either.hs view
@@ -184,6 +184,9 @@ Left l -> return (Left l) Right r -> runEitherT (k r) {-# INLINE (>>=) #-}+ fail = EitherT . fail+ {-# INLINE fail #-}+ instance Monad m => MonadError e (EitherT e m) where throwError = EitherT . return . Left