-
Notifications
You must be signed in to change notification settings - Fork 13.9k
Refactor move analysis subpath representation #147575
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
Conversation
|
Some changes occurred to MIR optimizations cc @rust-lang/wg-mir-opt This PR changes MIR cc @oli-obk, @RalfJung, @JakobDegen, @vakaras The rustc-dev-guide subtree was changed. If this PR only touches the dev guide consider submitting a PR directly to rust-lang/rustc-dev-guide otherwise thank you for updating the dev guide with your changes. |
|
rustbot has assigned @jdonszelmann. Use |
This comment has been minimized.
This comment has been minimized.
|
☔ The latest upstream changes (presumably #147574) made this pull request unmergeable. Please resolve the merge conflicts. |
|
Haven't reviewed the validation yet, but the main part lgtm and is an improvement in readability and maintainability |
efc1a27 to
776ab3d
Compare
This comment has been minimized.
This comment has been minimized.
|
r=me after another rebase |
776ab3d to
bce7f71
Compare
|
This PR was rebased onto a different master commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
|
r? ralfjung |
|
@jdonszelmann Uh, why me? I don't know any of this code... I just commented on like a 3-line change in r? @oli-obk |
|
|
|
@bors r+ |
Refactor move analysis subpath representation Follow up to #147055 This PR does two things: 1. Document/validate move analysis's assumptions about `Subslice` projections 2. Decouple move paths from `ProjectionElem`, using a new enum `MoveSubPath` instead - This would be needed eventually when `ProjectionElem::Deref` is removed I wanted to do even more abstraction, making `MovePathLookup::find` return an iterator to remove the special handling of subslices in borrowck, but that regressed diagnostics and just wasn't worth the complexity.
Rollup merge of #147575 - beepster4096:movesubpath, r=oli-obk Refactor move analysis subpath representation Follow up to #147055 This PR does two things: 1. Document/validate move analysis's assumptions about `Subslice` projections 2. Decouple move paths from `ProjectionElem`, using a new enum `MoveSubPath` instead - This would be needed eventually when `ProjectionElem::Deref` is removed I wanted to do even more abstraction, making `MovePathLookup::find` return an iterator to remove the special handling of subslices in borrowck, but that regressed diagnostics and just wasn't worth the complexity.
Rollup of 4 pull requests Successful merges: - rust-lang/rust#147575 (Refactor move analysis subpath representation) - rust-lang/rust#147864 (Parse `const unsafe trait` properly) - rust-lang/rust#147868 (MirPatch: Simplify new_local.) - rust-lang/rust#147873 (comments for deduce_param_attrs) r? `@ghost` `@rustbot` modify labels: rollup
Follow up to #147055
This PR does two things:
SubsliceprojectionsProjectionElem, using a new enumMoveSubPathinsteadProjectionElem::Derefis removedI wanted to do even more abstraction, making
MovePathLookup::findreturn an iterator to remove the special handling of subslices in borrowck, but that regressed diagnostics and just wasn't worth the complexity.