New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Initial conversion to ExceptT. #34
Conversation
This looks great! Is there any outstanding work that can be done to assist in getting this merged/released? |
@@ -59,57 +62,72 @@ import Data.Maybe (fromMaybe) | |||
import System.Exit (ExitCode) | |||
import System.IO (hPutStr, hPutStrLn, stderr) | |||
|
|||
exceptT :: Monad m => (a -> m c) -> (b -> m c) -> ExceptT a m b -> m c |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add the following documentation to these three functions:
-- | Fold an `ExceptT` by providing one continuation for each constructor
exceptT :: ...
-- | Transform the left and right value
bimapExceptT :: ...
-- | Upgrade an `Either` to an `ExceptT`
hoistEither :: ...
Initial conversion to ExceptT.
Alright, this looks good. Thanks for taking the time write up this large change. I'll put this up as |
Alright, so the remaining work is that I need to get as many downstream packages to add an |
Alright, so I will upload this to Hackage next weekend. Most downstream packages have either added an upper bound or have been given sufficient notice (warnings, pull requests, reminders to upload to Hackage, etc.). |
Alright, this is up on Hackage |
Supporting issue #32.
I provisionally renamed
throwE
,catchE
,handleE
, andflipE
tothrowEither
,catchEither
,handleEither
, andflipEither
becausethrowE
andcatchE
exist inControl.Monad.Trans.Except
. I also removedthrowT
andcatchT
because of that and instead renamedhandleT
tohandleE
.