The partiality monad

A continuation-passing encoding of Maybe; also known as
Codensity Maybe, if you're familiar with that terminology.
N.B., this is not the 2-continuation implementation based on the
Church encoding of Maybe. The latter tends to have worse
performance than non-continuation based implementations.

This is generally more efficient than using Maybe for two
reasons. First is that it right associates all binds, ensuring
that bad associativity doesn't artificially introduce midpoints
in short-circuiting to the nearest handler. Second is that it
removes the need for intermediate case expressions.

A version of maybe for convenience. This is almost identical
to mplus but allows applying a continuation to Just values
as well as handling Nothing errors. If you only want to handle
the errors, use mplus instead.