, not (the_tv `elemVarSet` untch)
, not (k `eqKind` default_k)
= do { (ev, better_ty) <- TcSMonad.newKindConstraint (mkTyVarTy the_tv) default_k
- ; let loc = CtLoc TypeEqOrigin (getSrcSpan the_tv) [] -- Yuk
+ ; let loc = CtLoc DefaultOrigin (getSrcSpan the_tv) [] -- Yuk
+ -- 'DefaultOrigin' is strictly the declaration, but it's convenient
wanted_eq = CTyEqCan { cc_id = ev
, cc_flavor = Wanted loc
, cc_tyvar = the_tv
| otherwise = filter is_defaultable_group (equivClasses cmp_tv unaries)
where
unaries :: [(CanonicalCt, TcTyVar)] -- (C tv) constraints
- non_unaries :: [CanonicalCt] -- *other* constraints
+ non_unaries :: [CanonicalCt] -- and *other* constraints
(unaries, non_unaries) = partitionWith find_unary (bagToList wanteds)
-- Finds unary type-class constraints