Proposal: require spaces around the dot operator

John Meacham john at
Mon Feb 13 09:41:25 CET 2012

On Mon, Feb 13, 2012 at 12:07 AM, AntC <anthony_clayden at> wrote:
> So the advantage of dot from that point of view is:
> * dot already appears tightly-bound in qualified names
> * dot is already a reserved operator,
>  so we won't have to search for some other candidate

(.) is not a reserved op, it is defined and redefinable
like every other operator and has no special fixity

main = do
    let x . y = x + y
    print (3 . 8)

prints 11 like you would expect.

Oddly enough, I have occasionally wanted (.) to bind tighter than function
application but still be composition. map toUpper.chr xs has a nice feel to
me :)


More information about the Haskell-prime mailing list