varBind :: TypeVarName -> Type -> TI Substitution
varBind v t | t == TypeVar v = return idSub
- | v `Set.member` freeVarsT t = fail $ "occur check failed: " ++ v ++ " in " ++ show t
+ | v `Set.member` freeVarsT t = fail $ "occur check failed: " ++ v ++ " ~ " ++ show t
| otherwise = return $ Map.singleton v t
instantiate :: TypeScheme -> TI Type