@@ -1446,7 +1446,7 @@ namespace {
1446
1446
if (auto *PD = dyn_cast<ParamDecl>(VD)) {
1447
1447
if (!CS.hasType (PD)) {
1448
1448
if (knownType && knownType->hasUnboundGenericType ())
1449
- knownType = CS.openUnboundGenericType (knownType, locator);
1449
+ knownType = CS.openUnboundGenericTypes (knownType, locator);
1450
1450
1451
1451
CS.setType (
1452
1452
PD, knownType ? knownType
@@ -1521,7 +1521,7 @@ namespace {
1521
1521
if (!type || type->hasError ()) return Type ();
1522
1522
1523
1523
auto locator = CS.getConstraintLocator (E);
1524
- type = CS.openUnboundGenericType (type, locator);
1524
+ type = CS.openUnboundGenericTypes (type, locator);
1525
1525
return MetatypeType::get (type);
1526
1526
}
1527
1527
@@ -2205,7 +2205,7 @@ namespace {
2205
2205
Type externalType;
2206
2206
if (param->getTypeRepr ()) {
2207
2207
auto declaredTy = param->getType ();
2208
- externalType = CS.openUnboundGenericType (declaredTy, paramLoc);
2208
+ externalType = CS.openUnboundGenericTypes (declaredTy, paramLoc);
2209
2209
} else {
2210
2210
// Let's allow parameters which haven't been explicitly typed
2211
2211
// to become holes by default, this helps in situations like
@@ -2439,7 +2439,7 @@ namespace {
2439
2439
// Look through reference storage types.
2440
2440
type = type->getReferenceStorageReferent ();
2441
2441
2442
- Type openedType = CS.openUnboundGenericType (type, locator);
2442
+ Type openedType = CS.openUnboundGenericTypes (type, locator);
2443
2443
assert (openedType);
2444
2444
2445
2445
auto *subPattern = cast<TypedPattern>(pattern)->getSubPattern ();
@@ -2541,7 +2541,7 @@ namespace {
2541
2541
if (!castType)
2542
2542
return Type ();
2543
2543
2544
- castType = CS.openUnboundGenericType (
2544
+ castType = CS.openUnboundGenericTypes (
2545
2545
castType,
2546
2546
locator.withPathElement (LocatorPathElt::PatternMatch (pattern)));
2547
2547
@@ -2607,7 +2607,7 @@ namespace {
2607
2607
if (!parentType)
2608
2608
return Type ();
2609
2609
2610
- parentType = CS.openUnboundGenericType (
2610
+ parentType = CS.openUnboundGenericTypes (
2611
2611
parentType, CS.getConstraintLocator (
2612
2612
locator, {LocatorPathElt::PatternMatch (pattern),
2613
2613
ConstraintLocator::ParentType}));
@@ -3100,7 +3100,7 @@ namespace {
3100
3100
3101
3101
// Open the type we're casting to.
3102
3102
const auto toType =
3103
- CS.openUnboundGenericType (type, CS.getConstraintLocator (expr));
3103
+ CS.openUnboundGenericTypes (type, CS.getConstraintLocator (expr));
3104
3104
if (repr) CS.setType (repr, toType);
3105
3105
3106
3106
auto fromType = CS.getType (fromExpr);
@@ -3127,7 +3127,7 @@ namespace {
3127
3127
3128
3128
// Open the type we're casting to.
3129
3129
const auto toType =
3130
- CS.openUnboundGenericType (type, CS.getConstraintLocator (expr));
3130
+ CS.openUnboundGenericTypes (type, CS.getConstraintLocator (expr));
3131
3131
if (repr) CS.setType (repr, toType);
3132
3132
3133
3133
auto fromType = CS.getType (expr->getSubExpr ());
@@ -3160,7 +3160,7 @@ namespace {
3160
3160
3161
3161
// Open the type we're casting to.
3162
3162
const auto toType =
3163
- CS.openUnboundGenericType (type, CS.getConstraintLocator (expr));
3163
+ CS.openUnboundGenericTypes (type, CS.getConstraintLocator (expr));
3164
3164
if (repr) CS.setType (repr, toType);
3165
3165
3166
3166
auto fromType = CS.getType (fromExpr);
@@ -3189,7 +3189,7 @@ namespace {
3189
3189
// Open up the type we're checking.
3190
3190
// FIXME: Locator for the cast type?
3191
3191
const auto toType =
3192
- CS.openUnboundGenericType (type, CS.getConstraintLocator (expr));
3192
+ CS.openUnboundGenericTypes (type, CS.getConstraintLocator (expr));
3193
3193
CS.setType (expr->getCastTypeRepr (), toType);
3194
3194
3195
3195
// Add a checked cast constraint.
@@ -3469,7 +3469,7 @@ namespace {
3469
3469
rootRepr, TypeResolverContext::InExpression);
3470
3470
if (!rootObjectTy || rootObjectTy->hasError ())
3471
3471
return Type ();
3472
- rootObjectTy = CS.openUnboundGenericType (rootObjectTy, locator);
3472
+ rootObjectTy = CS.openUnboundGenericTypes (rootObjectTy, locator);
3473
3473
// Allow \Derived.property to be inferred as \Base.property to
3474
3474
// simulate a sort of covariant conversion from
3475
3475
// KeyPath<Derived, T> to KeyPath<Base, T>.
0 commit comments