<div dir="ltr">+1 from me. <div><br></div><div>We routinely supply instances for tuples of up to 4 or 5 elements elsewhere. </div><div><br></div><div>There is no need to be randomly inconsistent here.</div><div><br></div><div>-Edward</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jan 18, 2016 at 3:10 PM, David Feuer <span dir="ltr"><<a href="mailto:david.feuer@gmail.com" target="_blank">david.feuer@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">For some reason I really can't imagine, it seems the only tuple type<br>
with a Functor instance is (,) a. I was astonished to find that<br>
<br>
fmap (+1) (1,2,3)<br>
<br>
doesn't work. Since this is *useful*, and there is *only one way to do<br>
it*, I propose we add the following:<br>
<br>
instance Functor ((,,) a b) where<br>
fmap f (a,b,c) = (a,b,f c)<br>
instance Functor ((,,,) a b c) where<br>
fmap f (a,b,c,d) = (a,b,c,f d)<br>
etc.<br>
<br>
I would really love to see these make 8.0.0, but if that's impossible<br>
then so be it.<br>
_______________________________________________<br>
Libraries mailing list<br>
<a href="mailto:Libraries@haskell.org">Libraries@haskell.org</a><br>
<a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries" rel="noreferrer" target="_blank">http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries</a><br>
</blockquote></div><br></div>