2014 Applicative => Monad proposal

Henning Thielemann lemming at henning-thielemann.de
Thu May 23 21:56:30 CEST 2013


On Thu, 23 May 2013, David Luposchainsky wrote:

> Let's make this happen! I'm going to give a ballpark discussion period
> of four weeks, but since I can imagine this discussion could become
> quite complex we shouldn't take it too serious. I'll summarize what's
> been going on periodically though.

I like the proposal and the plan for a transition.

I am only concerned with this one:

> - Promote `join` into the Monad typeclass

Currently, when I forget to implement the two essential Monad methods 
'return' and '>>=' in a Monad instance, I get a warning. However with the 
mutual implementations of 'join' and '>>=' I do not get a warning but an 
infinite loop. Similarly, I already had nasty bugs with (a-b) defaulting 
to (a + negate b) and (negate a) defaulting to (0-a).



More information about the Libraries mailing list