extra icon indicating copy to clipboard operation
extra copied to clipboard

Monadic Endo

Open crumbtoo opened this issue 2 years ago • 3 comments

Hello! This adds a very simple semigroup/monoid wrapper for functions a -> m a I find myself using often. Hoping someone has a better name than KEndo...

crumbtoo avatar Jan 16 '24 05:01 crumbtoo

Yeah, I don't love KEndo. Why the K? Why not MEndo (which I still don't love)?

ndmitchell avatar May 10 '24 12:05 ndmitchell

Why the K?

For the resemblance to Kleisli!

I've consulted the more creative; Any particularly strong feelings towards {EndoM, EndoKleisli, KleisliEndo}? EndoM is the most sensible in my opinion, following existing conventions.

crumbtoo avatar May 15 '24 11:05 crumbtoo

(Those more creative people have suggested matching Endo's composition order)

crumbtoo avatar May 15 '24 13:05 crumbtoo