[PATCH 1/3] Implement nand, nor, nany and nall in Data.List

Edward Kmett ekmett at gmail.com
Thu Feb 27 20:20:57 UTC 2014


I'm with Herbert on the -1.

They are easy enough compositions, so there is the Fairbairn threshold
argument, but then there is the fact that Data.List is a common unqualified
import, and that Data.Foldable _also_ exports versions of these
combinators, so for consistency would want these, and as that is heading
into the Prelude, the namespace pollution just gets worse.

-Edward


On Thu, Feb 27, 2014 at 12:28 PM, Herbert Valerio Riedel <hvr at gnu.org>wrote:

> Hello Alexander,
>
> While the patches are nicely done, I'm -1 on these additions, as I don't
> think there's enough value (in terms of Fairbairn threshold) to have
> these definitions added.
>
> Fwiw, I'd go even as far as saying that I wouldn't miss it if
> `Data.List.{and,or}` weren't defined in `base` as I'd rather use the
> 'All' and 'Any' newtypes with their Monoid instances or just
> `{all,any} id`, given that `Data.List{all,any}` are already taken by
> `map`-preprocessed versions of `and`/`or`.
>
> Cheers,
>
> On 2014-02-27 at 16:13:00 +0100, Alexander Berntsen wrote:
>
> [...]
>
> > +nand :: [Bool] -> Bool
> > +nand = not . and
>
> [...]
>
> > +nor :: [Bool] -> Bool
> > +nor = not . or
> _______________________________________________
> Libraries mailing list
> Libraries at haskell.org
> http://www.haskell.org/mailman/listinfo/libraries
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/libraries/attachments/20140227/fe39ea1b/attachment.html>


More information about the Libraries mailing list