Add missing Monad/Traversable instances to tuples
Edward Kmett
ekmett at gmail.com
Tue Apr 2 05:31:38 UTC 2019
I'm +1 on this on the grounds we established a few years back of adding
unambigously defined instances where they are well determined.
I've gone to reach for a couple of these before being stymied by their
absence in the past and had to build local data types or, worse, inflict
orphans on my users.
-Edward
On Tue, Apr 2, 2019 at 12:29 AM Fumiaki Kinoshita <fumiexcel at gmail.com>
wrote:
> I submitted https://gitlab.haskell.org/ghc/ghc/merge_requests/644 but it
> might be still controversial. I'd like to get more opinions again.
>
> Here's the list of proposed instances:
>
> Foldable ((,,) a b)
> Foldable ((,,,) a b c)
> Traversable ((,,) a b)
> Traversable ((,,,) a b c)
> Functor ((,,) a b)
> (Monoid a, Monoid b) => Applicative ((,,) a b)
> (Monoid a, Monoid b) => Monad ((,,) a b)
> Functor ((,,,) a b c)
> (Monoid a, Monoid b, Monoid c) => Applicative ((,,,) a b c)
> (Monoid a, Monoid b, Monoid c) => Monad ((,,,) a b c)
>
> The absence of Traversable instances for tuples feels quite inconsistent
> given that there are Bitraversable instances already.
> _______________________________________________
> Libraries mailing list
> Libraries at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/libraries/attachments/20190402/c9dec410/attachment.html>
More information about the Libraries
mailing list