Rollup merge of #113957 - Urgau:regression-test-issue-113941, r=dtolnay

Add regression test for issue #113941 - naive layout isn't refined

This PR adds a regression test for issue #113941 - `the naive layout isn't refined by the actual layout` based on the minimized repro https://github.com/rust-lang/rust/issues/113941#issuecomment-1646446769.
This commit is contained in:
Matthias Krüger 2023-07-22 19:57:37 +02:00 committed by GitHub
commit b7183bd167
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 13 additions and 0 deletions

View File

@ -0,0 +1,13 @@
// build-pass
// revisions: normal randomize-layout
// [randomize-layout]compile-flags: -Zrandomize-layout
enum Void {}
pub struct Struct([*const (); 0], Void);
pub enum Enum {
Variant(Struct),
}
fn main() {}