Proposal: infixr 9 `Compose`

Bas van Dijk v.dijk.bas at gmail.com
Tue Sep 3 09:37:49 CEST 2013


On 30 August 2013 18:45, Ross Paterson <R.Paterson at city.ac.uk> wrote:
> So I guess it's harmless for standard Haskell code but may be useful
> in GHC Haskell.

Yes that was my thinking to.

For the record, I don't recommend writing code like this:

  {-# LANGUAGE TypeOperators #-}

  a `Compose` b `Compose` c

I would prefer to write the parenthesis explicitly.

However, following the principle of least surprise I do think that
type composition should associate in the same way as function
composition.

Bas




More information about the Libraries mailing list