Skip to content

Conversation

zachs18
Copy link
Contributor

@zachs18 zachs18 commented Aug 14, 2025

09a3846 from #103693 made LayoutData be owned instead of interned in Variants::Multiple::variants1, so there's no need for TmpLayout in layout_of_enum anymore, and we can just store the variants' layouts directly in the prospective LayoutDatas' variants fields.

This should have no effect on semantics or layout.

(written as part of #145337 but not related to the layout optimizations in that PR)

Footnotes

  1. see line 1154 of compiler/rustc_target/src/abi/mod.rs in the linked commit; Variants::Multiple::variants effectively changed from IndexVec<.., Layout<'tcx>> to IndexVec<.., LayoutData> where the LayoutDatas are not interned as Layouts (LayoutData was at the time called LayoutS)

@rustbot
Copy link
Collaborator

rustbot commented Aug 14, 2025

r? @jackh726

rustbot has assigned @jackh726.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Aug 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant 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.

3 participants