-
Notifications
You must be signed in to change notification settings - Fork 10.4k
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
[Sema] Fix issue 65330 Unhelpful error when missing contextually requ… #65610
[Sema] Fix issue 65330 Unhelpful error when missing contextually requ… #65610
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the contribution!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks much better now! I think after my inline comments are addressed it would be ready to go.
Thank you very much for the feedback and also for getting back on #57540 . I have made changes accordingly for this PR. P.S. Do you happen to know of any other good starter bugs in swift-frontend? |
Regarding starter bugs I can definitely find you a few, are you interesting in the same general area? |
Yes please, I'm interested in starter bugs within the compiler front-end (Lexing/parsing/semantic analysis etc) |
…ired as bridging conversion to AnyObject in structural position. Minor formatting change in previous test case
@swift-ci please test |
@xedin Can you please merge the PR? I think I can merge it now that you have approved but Thanks for all the help! |
Feel free to merge yourself next time if the PR is approved and tests are green! I will leave some more starter bug issues in here on Monday. |
Got it, thank you! |
Example: protocol Integer {
}
func foo() -> some Integer {
let x = 0
x
} Doesn't produce a fix-it we'd expect.
|
…ired as bridging conversion to AnyObject in structural position.
Minor formatting change in previous test case
generic-subscript.swift
I'm not sure if these expressions should be considered to be contextual failures as well but it seemed reasonable. So this code change adds some custom logic in the contextual failure diagnosis for
TupleElement
locators when trying to diagnoseAnyObject
conversion failures.Resolves #65330