From: simonpj Date: Wed, 25 Jul 2001 08:04:00 +0000 (+0000) Subject: [project @ 2001-07-25 08:04:00 by simonpj] X-Git-Tag: Approximately_9120_patches~1417 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;ds=sidebyside;h=513e9c2f1f0ff3299222e10d6bb2903e8eb0138a;hp=7ca7d77a8ee046d26930792edd1a7b2b09a7870b;p=ghc-hetmet.git [project @ 2001-07-25 08:04:00 by simonpj] Change pretty-print of DmdType slightly --- diff --git a/ghc/compiler/basicTypes/NewDemand.lhs b/ghc/compiler/basicTypes/NewDemand.lhs index 291cf07..735c5ef 100644 --- a/ghc/compiler/basicTypes/NewDemand.lhs +++ b/ghc/compiler/basicTypes/NewDemand.lhs @@ -66,9 +66,11 @@ instance Outputable DmdType where ppr (DmdType fv ds res) = hsep [text "DmdType", hcat (map ppr ds) <> ppr res, - braces (fsep (map pp_elt (ufmToList fv)))] + if null fv_elts then empty + else braces (fsep (map pp_elt fv_elts))] where pp_elt (uniq, dmd) = ppr uniq <> text "->" <> ppr dmd + fv_elts = ufmToList fv instance Outputable DmdResult where ppr TopRes = empty -- Keep these distinct from Demand letters