Skip to content

Do anonymous lifetimes remapping correctly for nested rpits - #103205

Merged
bors merged 2 commits into
rust-lang:masterfrom
spastorino:fix-rpits-lifetime-remapping
Oct 20, 2022
Merged

Do anonymous lifetimes remapping correctly for nested rpits#103205
bors merged 2 commits into
rust-lang:masterfrom
spastorino:fix-rpits-lifetime-remapping

Conversation

@spastorino

Copy link
Copy Markdown
Member

Closes#103141

r? @cjgillot@nikomatsakis

This fixes a stable to stable regression that in my opinion is P-critical so, we probably want to backport it all the way up to stable.

@rustbotrustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Oct 18, 2022
@rust-highfiverust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Oct 18, 2022
@spastorinospastorino changed the title Do lifetimes remapping correctly for nested rpitsDo anonymous lifetimes remapping correctly for nested rpitsOct 18, 2022
Comment threadcompiler/rustc_ast_lowering/src/lib.rs Outdated
Comment threadcompiler/rustc_ast_lowering/src/lib.rs Outdated
@spastorino
spastorinoforce-pushed the fix-rpits-lifetime-remapping branch from f693233 to 7cce7e8CompareOctober 18, 2022 18:16
@spastorino

Copy link
Copy Markdown
MemberAuthor

@cjgillot, pushed a different change that changes the remappings to always be from the main outermost def_id, the innermost ones. That means that the remapping chain shouldn't be needed.

@spastorinospastorino added beta-nominated Nominated for backporting to the compiler in the beta channel. stable-nominated Nominated for backporting to the compiler in the stable channel. labels Oct 18, 2022
@spastorino
spastorinoforce-pushed the fix-rpits-lifetime-remapping branch from 7cce7e8 to 39ec7cdCompareOctober 19, 2022 13:57
@rustbotrustbot added the A-testsuite Area: The testsuite used to check the correctness of rustc label Oct 19, 2022
@spastorino

Copy link
Copy Markdown
MemberAuthor

@cjgillot this is ready now. I've just pushed again because I've found that's better to have the same set of "orig" methods and remapped methods, said orig_local_def_id and orig_opt_local_def_id as we have local_def_id and opt_local_def_id. That saves to unwrap in the call site.

@spastorino
spastorinoforce-pushed the fix-rpits-lifetime-remapping branch from 39ec7cd to 49ce8a2CompareOctober 19, 2022 19:50
@cjgillot

Copy link
Copy Markdown
Contributor

@bors r+ rollup=never

@bors

bors commented Oct 19, 2022

Copy link
Copy Markdown
Collaborator

📌 Commit 49ce8a2 has been approved by cjgillot

It is now in the queue for this repository.

@borsbors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Oct 19, 2022
@bors

bors commented Oct 20, 2022

Copy link
Copy Markdown
Collaborator

⌛ Testing commit 49ce8a2 with merge ebdde35...

@bors

bors commented Oct 20, 2022

Copy link
Copy Markdown
Collaborator

☀️ Test successful - checks-actions
Approved by: cjgillot
Pushing ebdde35 to master...

@borsbors added the merged-by-bors This PR was explicitly merged by bors. label Oct 20, 2022
@bors
bors merged commit ebdde35 into rust-lang:masterOct 20, 2022
@rustbotrustbot added this to the 1.66.0 milestone Oct 20, 2022
@rust-timer

Copy link
Copy Markdown
Collaborator

Finished benchmarking commit (ebdde35): comparison URL.

Overall result: no relevant changes - no action needed

@rustbot label: -perf-regression

Instruction count

This benchmark run did not return any relevant results for this metric.

Max RSS (memory usage)

Results

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean1rangecount2
Regressions ❌
(primary)
--0
Regressions ❌
(secondary)
--0
Improvements ✅
(primary)
--0
Improvements ✅
(secondary)
-2.2%[-2.2%, -2.2%]1
All ❌✅ (primary)--0

Cycles

This benchmark run did not return any relevant results for this metric.

Footnotes

  1. the arithmetic mean of the percent change

  2. number of relevant changes

@apiraino

apiraino commented Oct 20, 2022

Copy link
Copy Markdown
Contributor

Beta backport accepted as per compiler team on Zulip

@rustbot label +beta-accepted

@rustbotrustbot added beta-accepted Accepted for backporting to the compiler in the beta channel. stable-accepted Accepted for backporting to the compiler in the stable channel. labels Oct 20, 2022
@apirainoapiraino removed the stable-accepted Accepted for backporting to the compiler in the stable channel. label Oct 20, 2022
@cuvipercuviper mentioned this pull request Oct 20, 2022
@cuvipercuviper modified the milestones: 1.66.0, 1.65.0Oct 20, 2022
@cuvipercuviper removed the beta-nominated Nominated for backporting to the compiler in the beta channel. label Oct 20, 2022
bors added a commit to rust-lang-ci/rust that referenced this pull request Oct 21, 2022
[beta] backports
- Use rebind instead of dummy binder in `SameTypeModuloInfer` relation rust-lang#102059
- Add missing space between notable trait tooltip and where clause rust-lang#102107
- Avoid repeated re-initialization of the BufReader buffer rust-lang#102760
- Ensure enum cast moves rust-lang#103016
- Fix `TyKind::is_simple_path` rust-lang#103176
- Do anonymous lifetimes remapping correctly for nested rpits rust-lang#103205
- [beta] Cargo backport 1.65.0 rust-lang#103303
- linker: Fix weak lang item linking with combination windows-gnu + LLD + LTO rust-lang#103092
r? `@ghost`
@spastorino

Copy link
Copy Markdown
MemberAuthor

@rustbotrustbot added stable-accepted Accepted for backporting to the compiler in the stable channel. and removed stable-nominated Nominated for backporting to the compiler in the stable channel. labels Oct 21, 2022
@spastorino

Copy link
Copy Markdown
MemberAuthor

@cuviper this was meant to be stable-accepted, unsure if you need to revisit something here.

@cuviper

Copy link
Copy Markdown
Member

For stable backports, we wait until there's an actual stable point release in motion, but it should keep both labels until then so we know it hasn't been done.

@cuvipercuviper added the stable-nominated Nominated for backporting to the compiler in the stable channel. label Oct 21, 2022
@apirainoapiraino added the beta-nominated Nominated for backporting to the compiler in the beta channel. label Oct 21, 2022
@cuviper

Copy link
Copy Markdown
Member

I already included this one in beta, #103316.

@rustbot label -beta-nominated

@rustbotrustbot removed the beta-nominated Nominated for backporting to the compiler in the beta channel. label Oct 21, 2022
Aaron1011 pushed a commit to Aaron1011/rust that referenced this pull request Jan 6, 2023
…ing, r=cjgillot
Do anonymous lifetimes remapping correctly for nested rpits
Closesrust-lang#103141
r? `@cjgillot` `@nikomatsakis`
This fixes a stable to stable regression that in my opinion is `P-critical` so, we probably want to backport it all the way up to stable.
@Mark-SimulacrumMark-Simulacrum removed stable-nominated Nominated for backporting to the compiler in the stable channel. stable-accepted Accepted for backporting to the compiler in the stable channel. labels Mar 19, 2023
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-testsuiteArea: The testsuite used to check the correctness of rustcbeta-acceptedAccepted for backporting to the compiler in the beta channel.merged-by-borsThis PR was explicitly merged by bors.S-waiting-on-borsStatus: Waiting on bors to run and complete tests. Bors will change the label on completion.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Rust update from 1.63 to 1.64 introduce lifetime problem on build

9 participants

@spastorino@cjgillot@bors@rust-timer@apiraino@cuviper@Mark-Simulacrum@rust-highfive@rustbot