
5 Dec
2012
5 Dec
'12
3:23 a.m.
Hi Herbert, On Tue, Dec 04, 2012 at 11:02:07PM +0100, Herbert Valerio Riedel wrote:
btw, what I've been missing even more than isLeft/isRight is something like
leftMaybe :: Either a b -> Maybe a leftMaybe (Left x) = Just x leftMaybe _ = Nothing
rightMaybe :: Either a b -> Maybe b rightMaybe (Right x) = Just x rightMaybe _ = Nothing
There seems to be support for this. I think it would be useful to have a separate proposal/patch. Cheers, Simon