- ; let get_tvs | isTopLevel top_lvl = tyVarsOfType
- | otherwise = exactTyVarsOfType
- -- See Note [Silly type synonym] in TcType
- tau_tvs = foldr (unionVarSet . get_tvs . getMonoType) emptyVarSet mono_infos
-
- ; (qtvs, givens, ev_binds) <- simplifyInfer mono tau_tvs wanted
+ ; let name_taus = [(name, idType mono_id) | (name, _, mono_id) <- mono_infos]
+ ; (qtvs, givens, ev_binds) <- simplifyInfer top_lvl mono name_taus wanted