Proposal: Add "writer" Monad instance (, ) o to Control.Monad.Instances

Bas van Dijk v.dijk.bas at
Thu Sep 23 14:35:01 EDT 2010

On Thu, Sep 23, 2010 at 5:58 PM, Jake McArthur <jake.mcarthur at> wrote:
>> I'd like to have a (,)-style writer instance alongside the (->)-based
>> reader instance for Monad in Control.Monad.Instances.


On Thu, Sep 23, 2010 at 6:19 PM, Felipe Lessa <felipe.lessa at> wrote:
> I would just like to change ((,) o) to ((,) a) to be consistent with
> the Applicative instance [1].

Not that I find this terribly important, but I'm more in favor of
making the variable names descriptive and consistent with
mtl/transformers. So:

((->) r) a  i.e.  Reader r a

((,) w) a  i.e.  Writer w a

Also the 'a' in ((,) a) is confusing since the 'value' parameter of a
Monad is usually also called 'a', as in 'Reader r a'.



More information about the Libraries mailing list