Proposal #3339: Add (+>) as a synonym for mappend

Malcolm Wallace malcolm.wallace at
Mon Nov 7 11:00:30 CET 2011

On 7 Nov 2011, at 01:19, Duncan Coutts wrote:

>> The concrete example is in ghc:
>>    ptext (sLit "In module")
>> <+> quotes (ppr (is_mod decl_spec))
>> <+> source_import <> colon
> BTW, I should note that it looks like this is the only instance of this
> problem in the whole of ghc 

So let's just fix ghc here.  It looks to me like whoever wrote that code was relying on a non-obvious consequence of the precedence.  At a glance, it looks like there is intended to be a space before the source_import and colon.  And that is exactly what the proposed fixities for <> and <+> will give.  I find it hard to believe that many people would consciously have relied on the older behaviour.


More information about the Libraries mailing list