On Wed, 17 Feb 2010, Neil Brown wrote:

I very often write this too (wanting function composition, but with a two-argument function on the right hand side). The trick I picked up from somewhere is to do:

fun = (runFun .) . someFun someDefault

I'm not too keen on that, as it seems clumsy. I often end up writing the operator that you describe, but have never settled on a consistent name (since the obvious one to me, (..), is taken).

Maybe helpful:
 http://www.haskell.org/haskellwiki/Composing_functions_with_multiple_values

_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to