Commit d9bb0ee7 authored by Simon Peyton Jones's avatar Simon Peyton Jones

Don't print evidence in TcFlatten

Because when flattening a Derived constraint, the evidence doesn't exist
(it's an error thunk)
parent 168c8831
...@@ -920,7 +920,7 @@ flatten_one (TyVarTy tv) ...@@ -920,7 +920,7 @@ flatten_one (TyVarTy tv)
Right (ty1, co1) -- Recurse Right (ty1, co1) -- Recurse
-> do { (ty2, co2) <- flatten_one ty1 -> do { (ty2, co2) <- flatten_one ty1
; traceFlat "flattenTyVar2" (ppr tv $$ ppr ty2 $$ ppr co1) ; traceFlat "flattenTyVar2" (ppr tv $$ ppr ty2)
; return (ty2, co2 `mkTcTransCo` co1) } } ; return (ty2, co2 `mkTcTransCo` co1) } }
flatten_one (AppTy ty1 ty2) flatten_one (AppTy ty1 ty2)
...@@ -937,7 +937,7 @@ flatten_one (AppTy ty1 ty2) ...@@ -937,7 +937,7 @@ flatten_one (AppTy ty1 ty2)
= do { (xi2,co2) <- setEqRel eq_rel2 $ flatten_one ty2 = do { (xi2,co2) <- setEqRel eq_rel2 $ flatten_one ty2
; traceFlat "flatten/appty" ; traceFlat "flatten/appty"
(ppr ty1 $$ ppr ty2 $$ ppr xi1 $$ (ppr ty1 $$ ppr ty2 $$ ppr xi1 $$
ppr co1 $$ ppr xi2 $$ ppr co2) ppr co1 $$ ppr xi2)
; role1 <- getRole ; role1 <- getRole
; let role2 = eqRelRole eq_rel2 ; let role2 = eqRelRole eq_rel2
; return ( mkAppTy xi1 xi2 ; return ( mkAppTy xi1 xi2
...@@ -1104,7 +1104,7 @@ flatten_exact_fam_app_fully tc tys ...@@ -1104,7 +1104,7 @@ flatten_exact_fam_app_fully tc tys
| (flav, NomEq) `canRewriteOrSameFR` flavour_role | (flav, NomEq) `canRewriteOrSameFR` flavour_role
-> -- Usable hit in the flat-cache -> -- Usable hit in the flat-cache
-- We certainly *can* use a Wanted for a Wanted -- We certainly *can* use a Wanted for a Wanted
do { traceFlat "flatten/flat-cache hit" $ (ppr tc <+> ppr xis $$ ppr rhs_ty $$ ppr co) do { traceFlat "flatten/flat-cache hit" $ (ppr tc <+> ppr xis $$ ppr rhs_ty)
; (fsk_xi, fsk_co) <- flatten_one rhs_ty ; (fsk_xi, fsk_co) <- flatten_one rhs_ty
-- The fsk may already have been unified, so flatten it -- The fsk may already have been unified, so flatten it
-- fsk_co :: fsk_xi ~ fsk -- fsk_co :: fsk_xi ~ fsk
...@@ -1131,7 +1131,7 @@ flatten_exact_fam_app_fully tc tys ...@@ -1131,7 +1131,7 @@ flatten_exact_fam_app_fully tc tys
, cc_fsk = fsk } , cc_fsk = fsk }
; emitFlatWork ct ; emitFlatWork ct
; traceFlat "flatten/flat-cache miss" $ (ppr fam_ty $$ ppr fsk $$ ppr ev) ; traceFlat "flatten/flat-cache miss" $ (ppr fam_ty $$ ppr fsk)
; return (fsk_ty, maybeTcSubCo eq_rel ; return (fsk_ty, maybeTcSubCo eq_rel
(mkTcSymCo co) (mkTcSymCo co)
`mkTcTransCo` ret_co) } `mkTcTransCo` ret_co) }
......
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