[Type checker] Move TypeChecker::resolveType() into TypeResolution.

Now that type resolution is (almost completely) separated from the type
checker instance, move resolveType() out to TypeResolution where it
belongs.
This commit is contained in:
Doug Gregor
2018-08-20 22:31:59 -07:00
parent 0eaa00a470
commit 8dc20dfcac
10 changed files with 288 additions and 293 deletions

View File

@@ -1420,8 +1420,8 @@ namespace {
Type resolveTypeReferenceInExpression(TypeRepr *rep) {
TypeResolutionOptions options(TypeResolverContext::InExpression);
options |= TypeResolutionFlags::AllowUnboundGenerics;
return CS.TC.resolveType(rep, TypeResolution::forContextual(CS.DC),
options);
return TypeResolution::forContextual(CS.DC).resolveType(rep,
options);
}
Type visitTypeExpr(TypeExpr *E) {