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.

On Fri, Dec 23, 2016 at 7:02 PM, Baldur Blöndal <baldurpet@gmail.com> wrote:
Let's see if any of these are useful (a lot more at https://ghc.haskell.org/trac/ghc/ticket/13026)

(||||) :: (f a -> b) -> (g a -> b) -> ((Sum f g) a -> b) 
f |||| g = \case 
  InL fa -> f fa 
  InR ga -> g ga 

(&&&&) :: (a -> f b) -> (a -> g b) -> (a -> (Product f g) b) 
(f &&&& g) a = f a `Pair` g a 

I couldn't think of any for Data.Functor.Compose, names are up for bikeshedding

_______________________________________________
Libraries mailing list
Libraries@haskell.org
http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries




--
-Andrew Thaddeus Martin