Fix layout of simd types and respect align in mir interpreter

This commit is contained in:
hkalbasi 2023-07-02 00:42:33 +03:30
parent 15a0da6f30
commit 6f7452882a
6 changed files with 189 additions and 22 deletions

View file

@ -270,6 +270,20 @@ struct Goal(Foo<S>);
);
}
#[test]
fn simd_types() {
check_size_and_align(
r#"
#[repr(simd)]
struct SimdType(i64, i64);
struct Goal(SimdType);
"#,
"",
16,
16,
);
}
#[test]
fn return_position_impl_trait() {
size_and_align_expr! {