
+1 (yes, please). On Thu, May 16, 2013 at 4:33 AM, David Luposchainsky < dluposchainsky@googlemail.com> wrote:
Hello everyone,
I recently went through GHC's source, and discovered there are quite a few instances of Monad that don't have Functor or Applicative instances. Fixing this is very easy by adding the standard instances (pure = return etc.), and will not break code.
There is one exception to this: Hoopl defines its own (<*>). However, since it does not seem to have any packages depend on it otherwise, renaming this operator is also easily done (the thing is only used ten times or so). I called it (<*|*>) to complement (|*><*|), but naming should be the least important issue here.
Small piece of backstory: The idea behind this is making GHC future-proof for changing Applicative to be a superclass of Monad. However, I think adding the Applicative instances is a good idea regardless of whether this will ever happen, so that's the only thing I'm proposing right now.
Greetings, David
_______________________________________________ Libraries mailing list Libraries@haskell.org http://www.haskell.org/mailman/listinfo/libraries