-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Generic Associated Types in Trait Paths - Ast part #79266
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @petrochenkov (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
Looks great, I left some comments, mostly about error wording and formatting. |
Implemented the suggestions and addressed one of your comments on raising an error when |
Failing the CI tests because of formatting issues. I did call |
src/test/ui/generic-associated-types/parse/issue-67510-6.stderr
Outdated
Show resolved
Hide resolved
src/test/ui/generic-associated-types/parse/trait-path-expressions.rs
Outdated
Show resolved
Hide resolved
r=me after waiting for green CI and squashing commits. |
| | ||
LL | let sr: Vec<(u32, _, _) = vec![]; | ||
| -- ^ expected one of `,` or `>` | ||
| -- ^^^^^^^^^^^ |
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.
this diagnostic is somewhat unfortunate?
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.
Agree. Improving diagnostics will be done in a separate PR.
41d899d
to
1206495
Compare
Not sure what is the status here. @b-naber, could you address #79266 (comment) and squash the remaining commits? |
…ents in AssocTyConstraints haven't been fully implemented
1206495
to
2d18e88
Compare
2d18e88
to
5c4568d
Compare
Should be fixed now. |
Also addressed your comment, not sure why it's not shown as outdated yet. |
Thanks! |
📌 Commit 5c4568d has been approved by |
⌛ Testing commit 5c4568d with merge 585713a038fc284d0a7d79e2daac755d17446b89... |
💔 Test failed - checks-actions |
@bors retry |
Sorry, accidentally closed this on my cell phone. |
@bors retry |
☀️ Test successful - checks-actions |
…r=petrochenkov Improve diagnostics when parsing angle args rust-lang#79266 introduced parsing of generic arguments in associated type constraints, this however resulted in possibly very confusing error messages in cases in which closing angle brackets were missing such as in `Vec<(u32, _, _) = vec![]`, which outputs an incorrectly parsed equality constraint error, as noted by `@cynecx.` This PR tries to provide better error messages in such cases. r? `@petrochenkov`
The Ast part of #78978
r? @petrochenkov