Commit 6850eb64 authored by Simon Peyton Jones's avatar Simon Peyton Jones
Browse files

Improve pretty-printing of IfaceCoercions

For some reason, unless you have -fprint-explicit-coercions, when
printing an explicit coercion we were then going to special trouble to
suppress the unique of a hole (which only happens during debugging
anyway).  This is bizarre.

So I deleted three lines of code -- hooray.
parent 9ef237b7
......@@ -1135,12 +1135,8 @@ ppr_co ctxt_prec (IfaceUnivCo IfaceUnsafeCoerceProv r ty1 ty2)
text "UnsafeCo" <+> ppr r <+>
pprParendIfaceType ty1 <+> pprParendIfaceType ty2
ppr_co ctxt_prec (IfaceUnivCo (IfaceHoleProv u) _ _ _)
= maybeParen ctxt_prec TyConPrec $
sdocWithDynFlags $ \dflags ->
if gopt Opt_PrintExplicitCoercions dflags
then braces $ ppr u
else braces $ text "a hole"
ppr_co _ctxt_prec (IfaceUnivCo (IfaceHoleProv u) _ _ _)
= braces $ ppr u
ppr_co _ (IfaceUnivCo _ _ ty1 ty2)
= angleBrackets ( ppr ty1 <> comma <+> ppr ty2 )
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment