<div dir="ltr">I do not like using infix operators as names. Similar to others, I like the Sum eliminator and am skeptical of the value that the &&&& operator provides.</div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Dec 23, 2016 at 7:02 PM, Baldur Blöndal <span dir="ltr"><<a href="mailto:baldurpet@gmail.com" target="_blank">baldurpet@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto"><div dir="auto">Let's see if any of these are useful (a lot more at <a href="https://ghc.haskell.org/trac/ghc/ticket/13026" target="_blank">https://ghc.haskell.org/trac/<wbr>ghc/ticket/13026</a>)</div><div dir="auto"><br></div><div dir="auto">(||||) :: (f a -> b) -> (g a -> b) -> ((Sum f g) a -> b) </div><div dir="auto">f |||| g = \case </div><div dir="auto">  InL fa -> f fa </div><div dir="auto">  InR ga -> g ga </div><div dir="auto"><br></div><div dir="auto">(&&&&) :: (a -> f b) -> (a -> g b) -> (a -> (Product f g) b) </div><div dir="auto">(f &&&& g) a = f a `Pair` g a <br></div><div dir="auto"><br></div><div dir="auto">I couldn't think of any for Data.Functor.Compose, names are up for bikeshedding</div></div>
<br>______________________________<wbr>_________________<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-<wbr>bin/mailman/listinfo/libraries</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">-Andrew Thaddeus Martin</div>
</div>