Add Applicative instance for STM

Bas van Dijk v.dijk.bas at
Sun May 16 12:36:56 EDT 2010

On Sun, May 16, 2010 at 4:19 PM, Ross Paterson <ross at> wrote:
> It might be simpler to have Control/Applicative.hs import GHC.Conc and
> define the instance.

The {-# SOURCE #-} import of Control.Applicative and the accompanying
boot file are indeed unfortunate. However, I like having the Functor,
Applicative and Monad instances in one place. But I can easily be
convinced if more people like it your way.

> Might as well define an Alternative instance too.

Good point, I will try adding them to the existing patches.

> It would also make sense to move the MonadPlus instance from Control.Monad.STM
> (where it is an orphan) to GHC.Conc.

I created a separate ticket for this (including patches):

But lets keep the discussion about that on this thread.

>> Discussion period: a few days, since I think this is hardly controversial.
> I think proposals should get at least a couple of weeks, even if they're
> straightforward.

Ok, let's set the period on 2 weeks. If this proposal does proves to
be controversial I will extend the period lateron.

Thanks for your comments and suggestions!


More information about the Libraries mailing list