2 ms·
Monads don't need to be methods. In fact every Haskell monad is not a "decorator with method chaining" because there are no methods in Haskell in the traditiona
by jerf 18y ago
Monads don't need to be methods. In fact every Haskell monad is not a "decorator with method chaining" because there are no methods in Haskell in the traditional sense, and even if you count classes, there's no constraint that a monadic value has to be involved with a class.
If you squint at Haskell to the point that you start seeing methods in all monad uses, you're squinting so hard that the word "method" has lost all meaning and become a synonym for "function". That is to say, I can see how that argument goes, but it comes at the cost of totally devaluing the distinction between "method" and "function", something I'm not willing to do.