[GHC] #974: Add unzipEithers, lefts, rights to Data.Either

Aaron Denney wnoise at ofb.net
Mon Nov 13 13:00:02 EST 2006


On 2006-11-13, roconnor at theorem.ca <roconnor at theorem.ca> wrote:
> My reason for adding [Either a b] -> ([a],[b]) is that at least two 
> independent projects from independent authors use it and it seems 
> generally widely useful.  Althought techinically I don't have the same 
> evidence for lefts and rights, I believe such evidence exists.  At least 
> one instance is for specifying the behaviour of unzipEithers, which is why 
> I include it in the same patch.

Well since f x = (lefts x, rights x), why not name f "leftsAndRights",
or "boths", or some such?

-- 
Aaron Denney
-><-



More information about the Libraries mailing list