Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

To be a Monad you have to implement at least 2 functions >>=, and return, which must follow so called Monadic laws (of proper composition - associativity, etc). flatMap is just a function.

One more time - Futures are orthogonal to Monads. They may be viewed as such, but it is not necessary. Having only flatMap is sufficient for a strict language.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: