
On Mon, 13 Nov 2006, Ross Paterson wrote:
On Sun, Nov 12, 2006 at 11:40:19AM -0500, roconnor@theorem.ca wrote:
Everyone seems satified with the name unzipEithers. There have been suggestions for
partitionEither :: (a -> Either b c) -> [a] -> ([b], [c])
but I suggest they be pursued in a different trac.
I think it makes sense to consider them together, as these functions are closely related, the only concerns anyone has raised about them relate to names, and they're competing for the same part of the namespace.
But is this function (a -> Either b c) -> [a] -> ([b],[c]) defined by anyone and/or used anywhere? If not, is there any evidence that people will use this function in the future if it is added? 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. However I'm not convinced that there is demand fur the (a -> Either b c) -> [a] -> ([b],[c]) function. This is my concern. Since no one is suggesting the name of partitionEithers for the [Either a b] -> ([a],[b]) function anymore, there is currently no name space dispute. For these reasons, I suggest (a -> Either b c) -> [a] -> ([b],[c]) be pursued in another trac. -- Russell O'Connor http://r6.ca/ ``All talk about `theft,''' the general counsel of the American Graphophone Company wrote, ``is the merest claptrap, for there exists no property in ideas musical, literary or artistic, except as defined by statute.''