X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2Fmain%2FPprTyThing.hs;h=d859784fad746f86a03fcd25c05175128bdffbfb;hp=b10a31defe353737e7a4c8518254620854116f7d;hb=d2ce0f52d42edf32bb9f13796e6ba6edba8bd516;hpb=0084ab49ab3c0123c4b7f9523d092af45bccfd41 diff --git a/compiler/main/PprTyThing.hs b/compiler/main/PprTyThing.hs index b10a31d..d859784 100644 --- a/compiler/main/PprTyThing.hs +++ b/compiler/main/PprTyThing.hs @@ -112,7 +112,7 @@ pprTyConHdr _ tyCon | otherwise = sLit "data" opt_family - | GHC.isOpenTyCon tyCon = ptext (sLit "family") + | GHC.isFamilyTyCon tyCon = ptext (sLit "family") | otherwise = empty opt_stupid -- The "stupid theta" part of the declaration @@ -149,15 +149,15 @@ pprTypeForUser :: PrintExplicitForalls -> GHC.Type -> SDoc -- (C a, Ord b) => stuff pprTypeForUser print_foralls ty | print_foralls = ppr tidy_ty - | otherwise = ppr (mkPhiTy [p | (_tvs, ps) <- ctxt, p <- ps] ty') + | otherwise = ppr (mkPhiTy ctxt ty') where tidy_ty = tidyTopType ty - (ctxt, ty') = tcMultiSplitSigmaTy tidy_ty + (_, ctxt, ty') = tcSplitSigmaTy tidy_ty pprTyCon :: PrintExplicitForalls -> ShowMe -> TyCon -> SDoc pprTyCon pefas show_me tyCon | GHC.isSynTyCon tyCon - = if GHC.isOpenTyCon tyCon + = if GHC.isFamilyTyCon tyCon then pprTyConHdr pefas tyCon <+> dcolon <+> pprTypeForUser pefas (GHC.synTyConResKind tyCon) else