1
Fork 0

Implement Deref<LayoutS> for Layout

This commit is contained in:
Lukas Wirth 2023-09-29 18:00:06 +02:00
parent 67e5eb6cec
commit 6d141c11c0
4 changed files with 11 additions and 4 deletions

View file

@ -85,7 +85,7 @@ fn univariant_uninterned<'tcx>(
fields: &IndexSlice<FieldIdx, Layout<'_>>,
repr: &ReprOptions,
kind: StructKind,
) -> Result<LayoutS, &'tcx LayoutError<'tcx>> {
) -> Result<LayoutS<FieldIdx, VariantIdx>, &'tcx LayoutError<'tcx>> {
let dl = cx.data_layout();
let pack = repr.pack;
if pack.is_some() && repr.align.is_some() {