summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Peyton Jones <simonpj@microsoft.com>2016-06-24 09:03:01 +0100
committerSimon Peyton Jones <simonpj@microsoft.com>2016-06-24 11:04:31 +0100
commitbb84ee44e30eeedce37ce6b09684747e2c659836 (patch)
tree458d57a0a2be6526610fe400fa692ae913aa290d
parentf86a33792459bea26fe27ae1086aa161bd046a0a (diff)
downloadhaskell-bb84ee44e30eeedce37ce6b09684747e2c659836.tar.gz
Improve pretty-printing of Avail
-rw-r--r--compiler/basicTypes/Avail.hs7
1 files changed, 5 insertions, 2 deletions
diff --git a/compiler/basicTypes/Avail.hs b/compiler/basicTypes/Avail.hs
index 9595abc3ff..4dc6cb6cce 100644
--- a/compiler/basicTypes/Avail.hs
+++ b/compiler/basicTypes/Avail.hs
@@ -171,8 +171,11 @@ instance Outputable AvailInfo where
ppr = pprAvail
pprAvail :: AvailInfo -> SDoc
-pprAvail (Avail _ n) = ppr n
-pprAvail (AvailTC n ns fs) = ppr n <> braces (hsep (punctuate comma (map ppr ns ++ map (ppr . flLabel) fs)))
+pprAvail (Avail _ n)
+ = ppr n
+pprAvail (AvailTC n ns fs)
+ = ppr n <> braces (sep [ fsep (punctuate comma (map ppr ns)) <> semi
+ , fsep (punctuate comma (map (ppr . flLabel) fs))])
instance Binary AvailInfo where
put_ bh (Avail b aa) = do