[ConstraintFix] Rather than creating a coalesced fix right before

diagnosing failures in applySolutionFixes, coalesce fixes and
diagnose failures in one method on ConstraintFix.

This eliminates the need for the `DefaultGenericArgument` fix (which
was renamed from `ExplicitlySpecifyGenericArguments`) to have an
array of missing parameters, which was only used when the fixes were
coalesced. Instead, the coalesced arguments are used to create the
`MissingGenericArgumentsFailure` diagnostic directly.
This commit is contained in:
Holly Borla
2019-11-08 17:19:31 -08:00
parent 212f20245a
commit ea1a46c84d
5 changed files with 48 additions and 75 deletions

View File

@@ -8390,7 +8390,7 @@ ConstraintSystem::SolutionKind ConstraintSystem::simplifyFixConstraint(
case FixKind::AllowAnyObjectKeyPathRoot:
case FixKind::TreatKeyPathSubscriptIndexAsHashable:
case FixKind::AllowInvalidRefInKeyPath:
case FixKind::ExplicitlySpecifyGenericArguments:
case FixKind::DefaultGenericArgument:
case FixKind::GenericArgumentsMismatch:
case FixKind::AllowMutatingMemberOnRValueBase:
case FixKind::AllowTupleSplatForSingleParameter: