mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[Completion] Downgrade a couple of ASSERTs for 6.2
This commit is contained in:
@@ -393,8 +393,14 @@ static TypeRelation calculateTypeRelation(Type Ty, Type ExpectedTy,
|
||||
return TypeRelation::Unknown;
|
||||
}
|
||||
|
||||
ASSERT(!Ty->hasUnboundGenericType() && !ExpectedTy->hasUnboundGenericType());
|
||||
ASSERT(!ExpectedTy->hasTypeParameter());
|
||||
if (Ty->hasUnboundGenericType() || ExpectedTy->hasUnboundGenericType()) {
|
||||
CONDITIONAL_ASSERT(false && "Must not have unbound generic type here");
|
||||
return TypeRelation::Unrelated;
|
||||
}
|
||||
if (ExpectedTy->hasTypeParameter()) {
|
||||
CONDITIONAL_ASSERT(false && "Must not have generic type here");
|
||||
return TypeRelation::Unrelated;
|
||||
}
|
||||
|
||||
if (Ty->isEqual(ExpectedTy))
|
||||
return TypeRelation::Convertible;
|
||||
|
||||
Reference in New Issue
Block a user