Commit 6386fc32 authored by Simon Peyton Jones's avatar Simon Peyton Jones
Browse files

Comments and tc-tracing only

parent 75bf11c0
......@@ -527,7 +527,8 @@ solveOneFromTheOther ev_i ev_w
| CtWanted { ctev_loc = loc_w } <- ev_w
, prohibitedSuperClassSolve (ctEvLoc ev_i) loc_w
= return (IRDelete, False)
= do { traceTcS "prohibitedClassSolve1" (ppr ev_i $$ ppr ev_w)
; return (IRDelete, False) }
| CtWanted { ctev_dest = dest } <- ev_w
-- Inert is Given or Wanted
......@@ -536,7 +537,8 @@ solveOneFromTheOther ev_i ev_w
| CtWanted { ctev_loc = loc_i } <- ev_i -- Work item is Given
, prohibitedSuperClassSolve (ctEvLoc ev_w) loc_i
= return (IRKeep, False) -- Just discard the un-usable Given
= do { traceTcS "prohibitedClassSolve2" (ppr ev_i $$ ppr ev_w)
; return (IRKeep, False) } -- Just discard the un-usable Given
-- This never actually happens because
-- Givens get processed first
......@@ -877,6 +879,7 @@ interactDict inerts workItem@(CDictCan { cc_ev = ev_w, cc_class = cls, cc_tyargs
-- we solve it from the solution in the inerts we just retrieved.
Nothing -> do
{ (inert_effect, stop_now) <- solveOneFromTheOther ctev_i ev_w
; traceTcS "lookupInertDict" (ppr inert_effect <+> ppr stop_now)
; case inert_effect of
IRKeep -> return ()
IRDelete -> updInertDicts $ \ ds -> delDict ds cls tys
......
......@@ -2067,7 +2067,7 @@ solvable from the other. So, we do lookup in the inert set using
loose types, which omit the kind-check.
We must be careful when using the result of a lookup because it may
not match the requsted info exactly!
not match the requested info exactly!
-}
......
......@@ -2561,6 +2561,9 @@ sizeType = go
| isTypeFamilyTyCon tc = infinity -- Type-family applications can
-- expand to any arbitrary size
| otherwise = sizeTypes (filterOutInvisibleTypes tc tys) + 1
-- Why filter out invisible args? I suppose any
-- size ordering is sound, but why is this better?
-- I came across this when investigating #14010.
go (LitTy {}) = 1
go (FunTy arg res) = go arg + go res + 1
go (AppTy fun arg) = go fun + go arg
......
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