Re:Monads are monoids in the category of endofunctors
by edflsafoiewq on Friday September 10, 2021 @03:52PM
(#28486199)
> I've never seen a type with multiple monad instances but I don't know if there could be one.
There can, it's just like there can two monoid structures on the same set. In fact if you have an example of a set S which has two monoid structures, you have an example of a functor with two monad structures: _ × S. join multiplies the two elements of S, so you get a different monad structure for every monoid structure on S.
There can, it's just like there can two monoid structures on the same set. In fact if you have an example of a set S which has two monoid structures, you have an example of a functor with two monad structures: _ × S. join multiplies the two elements of S, so you get a different monad structure for every monoid structure on S.