New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[SR-4318] Useless diagnostic with type not conforming to Equatable #46901
Comments
There's no direct connection between |
I guess there is a connection if one of the candidates we find is in a protocol. Then we can suggest conforming to that protocol.
But that wouldn't help for something like |
There'd at least hopefully be fewer != overloads in the wild (and even fewer once conditional conformances work). |
The "connection if one of the candidates is in a protocol" sounds a lot like Doug's vague plan to optimize operator resolution by folding together candidates that look like a protocol conformance. I think the way we present this error is also pretty atrocious—I know it's all crammed in one note to work around Xcode's lack of good cross-file note support, but that's something that Xcode ought to fix. It'd still be somewhat more manageable to have one note per candidate. |
FYI Swift 3.1 produces the same result. |
I just filed SR-4795 with a similar problem. |
Still an issue in Swift 4.0 |
Still an issue in Swift 4.1 |
Attachment: Download
Environment
Swift version 3.0.2 (swiftlang-800.0.63 clang-800.0.42.1)
Swift version 3.1 (swiftlang-802.0.48 clang-802.0.48)
Swift version 4.0 (swiftlang-900.0.59 clang-900.0.34.2)
Swift version 4.1 (swiftlang-902.0.34 clang-902.0.30)
Additional Detail from JIRA
md5: 4231b4a94173b29ece8dca6219bf66e9
Issue Description:
Error:
In my project (with a not-reduced version of this) I actually get, quite literally, a lot of ambiguous references... (see screenshot)
The text was updated successfully, but these errors were encountered: