From: simonpj@microsoft.com Date: Mon, 10 Dec 2007 08:30:53 +0000 (+0000) Subject: Improve pretty-printing of InstDecl X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=commitdiff_plain;h=3403e40722df9ad29eef8ec6224112a57b4fa7fc Improve pretty-printing of InstDecl Fixes Trac #1966. --- diff --git a/compiler/hsSyn/HsDecls.lhs b/compiler/hsSyn/HsDecls.lhs index 0c9e7f4..4fcf602 100644 --- a/compiler/hsSyn/HsDecls.lhs +++ b/compiler/hsSyn/HsDecls.lhs @@ -752,10 +752,10 @@ data InstDecl name instance (OutputableBndr name) => Outputable (InstDecl name) where ppr (InstDecl inst_ty binds uprags ats) - = vcat [hsep [ptext SLIT("instance"), ppr inst_ty, ptext SLIT("where")], - nest 4 (ppr ats), - nest 4 (ppr uprags), - nest 4 (pprLHsBinds binds) ] + = vcat [hsep [ptext SLIT("instance"), ppr inst_ty, ptext SLIT("where")] + , nest 4 $ vcat (map ppr ats) + , nest 4 $ vcat (map ppr uprags) + , nest 4 $ pprLHsBinds binds ] -- Extract the declarations of associated types from an instance --