Print infix type constructors in an infix way
authorsimonpj@microsoft.com <unknown>
Mon, 25 Jun 2007 15:28:58 +0000 (15:28 +0000)
committersimonpj@microsoft.com <unknown>
Mon, 25 Jun 2007 15:28:58 +0000 (15:28 +0000)
commitb15724ad3cae2a14c265683e8bb6f7d639dac251
tree4d09ac1a76770a52c942232325b3c961b21a0e2d
parent75ebc06a512a374eebb562ce4190bef136e2c1d6
Print infix type constructors in an infix way

Fixes Trac #1425.  The printer for types doesn't know about fixities.
(It could be educated to know, but it doesn't at the moment.)  So it
treats all infix tycons as of precedence less than application and function
arrrow.

I took a slight shortcut and reused function-arrow prededence, so I think
you may get
T -> T :% T
meaning
T -> (T :% T)

If that becomes a problem we can fix it.
compiler/main/PprTyThing.hs
compiler/typecheck/TcEnv.lhs
compiler/types/FamInstEnv.lhs
compiler/types/TypeRep.lhs