Commit Graph

9 Commits

Author SHA1 Message Date
Henrik G. Olsson
cbc0ec3b88 Add -verify-ignore-unrelated where necessary (NFC)
These are tests that fail in the next commit without this flag. This
does not add -verify-ignore-unrelated to all tests with -verify, only
the ones that would fail without it. This is NFC since this flag is
currently a no-op.
2025-10-04 14:19:52 -07:00
Pavel Yaskevich
2e2792e3e3 [ConstraintSystem] Adjust diagnoseAmbiguity to use a local slice of overloads
Compute a slice of ambiguous overload choices related to an aggregated fix
and if such a slice points to a single overload diagnose it as non-ambiguous.
2020-11-06 10:42:25 -08:00
Pavel Yaskevich
82fcee7bc7 [Diagnostics] NFC: Adjust diagnostic test-cases improved by new ambiguity diagnosis 2020-06-12 13:13:27 -07:00
Pavel Yaskevich
694023ac7c [Diagnostics] Centralize requirement failure impact assessment
Conformance requirements get their fixes attached directly where
other requirements have to use (for now) `repairFailure` mechanism.

Regardless of _how_ fixes get recorded there should be a single
way to assess impact of a particular requirement failure.

The rules are:

- If this is a requirement associated with an operator, impact
  is based on use of the type which failed the requirement;

- If this requirement is from conditional extension,
  it is considered a very high impact because failing such
  requirement makes referenced member de facto invisible.

Resolves: rdar://problem/55593998
Resolves: [SR-11491](https://bugs.swift.org/browse/SR-11491)
2019-09-26 12:13:06 -07:00
Pavel Yaskevich
c30845fa74 [ConstraintSystem] Detect and diagnose missing generic arguments
Introduce a fix to detect and diagnose situations when omitted
generic arguments couldn't be deduced by the solver based on
the enclosing context.

Example:

```swift
struct S<T> {
}

_ = S() // There is not enough context to deduce `T`
```

Resolves: rdar://problem/51203824
2019-05-29 16:39:41 -07:00
Mark Lacey
78d83e5703 Use %target-typecheck-verify-swift where possible. 2018-07-26 23:13:43 -07:00
Joe Groff
cb26cd76bf Reenable KeyPath.appending tests that were crashing the type checker.
rdar://problem/31724834 appears to have been fixed.
2017-05-05 09:11:14 -07:00
Joe Groff
517c45aa3d Followups from merging master 2017-04-19 20:58:52 -07:00
Joe Groff
5ed6bd831e KeyPaths: Dynamic appending between possibly-mismatched types.
Make the `appending` operation between `AnyKeyPath` and `PartialKeyPath` values work. Add a test checking the combinations.
2017-04-04 11:31:15 -07:00