-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
WIP Generic associated types in trait paths #78978
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @lcnr (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. |
r? @petrochenkov for now |
@b-naber |
Meta 2: the diagnostics efforts in the parser can be deferred to a separate PR to make this PR smaller and more digestible so we can be sure that the core logic is correct. |
…ochenkov Generic Associated Types in Trait Paths - Ast part The Ast part of rust-lang#78978 r? `@petrochenkov`
☔ The latest upstream changes (presumably #79266) made this pull request unmergeable. Please resolve the merge conflicts. Note that reviewers usually do not review pull requests until merge conflicts are resolved! Once you resolve the conflicts, you should change the labels applied by bors to indicate that your PR is ready for review. Post this as a comment to change the labels:
|
Not sure whether this PR is fully superseded by #79554 or not, but I'm going to mark it as blocked on it. |
…-trait-paths, r=jackh726 Generic associated types in trait paths This is the second part of rust-lang#78978 This should fix: Fixes rust-lang#67510 Fixes rust-lang#68648 Fixes rust-lang#68649 Fixes rust-lang#68650 Fixes rust-lang#68652 Fixes rust-lang#74684 Fixes rust-lang#76535 Fixes rust-lang#79422 Fixes rust-lang#80433 and implement the remaining functionality needed for rust-lang#44265 r? `@matthewjasper`
…-trait-paths, r=jackh726 Generic associated types in trait paths This is the second part of rust-lang#78978 This should fix: Fixes rust-lang#67510 Fixes rust-lang#68648 Fixes rust-lang#68649 Fixes rust-lang#68650 Fixes rust-lang#68652 Fixes rust-lang#74684 Fixes rust-lang#76535 Fixes rust-lang#79422 Fixes rust-lang#80433 and implement the remaining functionality needed for rust-lang#44265 r? ``@matthewjasper``
Is supposed to fix #67510, #68648, #68649, #68650, #68652, #74684
@petrochenkov Asked me to open a WIP PR, so he can look at the part that was changed in the parser.
A couple of potential problems and things to work on are:
S::<5 + 2 >> 7>;
, which suggests that const expressions must be enclosed in braces, whereas with the current changes we get:expected one of
,or
>, found
+parse_assoc_equality_term
we returnOk(mk_ty(..., TyKind::Error))
unless the generic argument that is parsed in the beginning of the function is of typeGenericArg::Type
, but a TyKind::Error result is currently not handled after the call.bounds_reference_self
in object safety checking the map call that usedsubst_supertrait
was removed, I've talked to both @matthewjasper and @nikomatsakis about this and both didn't know why the call was there. All relevant ui tests still pass after the removal.