1
Fork 0

compiler: Wire {TyAnd,}Layout into rustc_abi

This finally unites TyAndLayout, Layout, and LayoutS into the same crate,
as one might imagine they would be placed. No functional changes.
This commit is contained in:
Jubilee Young 2024-10-09 12:20:28 -07:00
parent 255bdd2f24
commit 10721909f2
7 changed files with 279 additions and 253 deletions

View file

@ -11,6 +11,10 @@ use crate::{
Variants, WrappingRange,
};
mod ty;
pub use ty::{FIRST_VARIANT, FieldIdx, Layout, TyAbiInterface, TyAndLayout, VariantIdx};
// A variant is absent if it's uninhabited and only has ZST fields.
// Present uninhabited variants only require space for their fields,
// but *not* an encoding of the discriminant (e.g., a tag value).