This is a very simple type: It's much like Maybe, except instead of Nothing, we have Failure String. A comparison could also be made to Either String. I made this library because I was dissatisfied with the Monad instance for Either. In this type, fail = Failure. It's rather simple. Changes This release does not actually break the API, however I was rather tired when I chose the version number. This should be 0.1.6.


Keywords
bsd2, library, Control.Exceptional
License
BSD-3-Clause-Attribution
Install
cabal install exceptional-0.3.0.0

Documentation

exceptional

This is a Haskell library that exists to house a type:

data Exceptional x
  = Failure String
  | Success x

It's much like Maybe, except instead of Nothing, we have Failure String.

A comparison could also be made to Either String. I made this library because I was dissatisfied with the Monad instance for Either. In this type, fail = Failure. It's rather simple.

Installing

cabal install exceptional

Or, add exceptional to the build-depends field in your .cabal file.