Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What are arguments to a monad bind operation formally called?

For example, in the list monad bind operation:

xs >>= f = concat (map f xs)

What is the argument f called? A binder? mapper? transformer?

like image 833
Gowtham Kaki Avatar asked Feb 20 '14 04:02

Gowtham Kaki


1 Answers

Sorry to be glib, but the argument is called f, since depending on what it does, one of any number of names could be applicable. What matters, simply, is its type a -> m b for your Monad instance m. As David Yong's comment notes, we can describe things of that form as an "arrow (or morphism) in the Kleisli category of m".

like image 124
sclv Avatar answered Sep 19 '22 22:09

sclv