[Haskell-cafe] mtl: Why there is "Monoid w" constraint in the definition of class MonadWriter?

Roman Cheplyaka roma at ro-che.info
Sat Dec 8 23:00:52 CET 2012


* Edward Z. Yang <ezyang at MIT.EDU> [2012-12-08 11:19:01-0800]
> The monoid instance is necessary to ensure adherence to the monad laws.

This doesn't make any sense to me. Are you sure you're talking about the
MonadWriter class and not about the Writer monad?

Roman



More information about the Haskell-Cafe mailing list