mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Discourage constraint systems that use more unchecked forces.
This is in preparation for a change that allows unchecked-optional values to be implicitly forced in all contexts. Swift SVN r14704
This commit is contained in:
@@ -1360,6 +1360,7 @@ ConstraintSystem::simplifyMemberConstraint(const Constraint &constraint) {
|
||||
|
||||
// Try to look through UncheckedOptional<T>; the result is always an r-value.
|
||||
if (auto objTy = lookThroughUncheckedOptionalType(baseObjTy)) {
|
||||
increaseScore(SK_UncheckedForce);
|
||||
baseTy = baseObjTy = objTy;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user