[Haskell-cafe] From monads to monoids in a small category
Alberto G. Corona
agocorona at gmail.com
Wed Sep 5 00:12:18 CEST 2012
Not to mention the ugly formatting ;)
2012/9/5 Richard O'Keefe <ok at cs.otago.ac.nz>:
> On 4/09/2012, at 10:39 PM, Alberto G. Corona wrote:
>> "Monads are monoids in the category of endofunctors"
>> This Monoid instance for the endofunctors of the set of all elements
>> of (m a) typematch in Haskell with FlexibleInstances:
>> instance Monad m => Monoid (a -> m a) where
>> mappend = (>=>) -- kleisly operator
>> mempty = return
>> The article can be found here:
>> I would appreciate some comments.
> In the article,
> /Here 'm b' as/ s/as/is/
> s/this_are/this are/
> s/first, is/first is/
> s/x=/x =/
> s/condition, associativity/condition, associativity,/
> /if not where that way, .* guess/
> I *think* you mean to say something like
> (If it were not so, it would be impossible to
> define the denotational semantics of imperative
> languages in terms of monads, I guess.)
> Generally, it's "according TO", not "according WITH",
> and "associated WITH", not "associated TO".
> instance Functor a
> doesn't seem to be legal Haskell.
> At this point I stopped reading.
More information about the Haskell-Cafe