
2 Oct
2006
2 Oct
'06
8:44 p.m.
Hi All, I've been [trying to] grapple with the various monads and transformers, and it occurs to me that the standard instance for Either as a monadic type is unnecessarily restrictive. Is there a compelling reason that it is not just instance Monad (Either e) where return = Right (Left e) >>= f = Left e (Right x) >>= f = f x abort = Left Tom