diff options
| author | Oli Scherer <git-spam-no-reply9815368754983@oli-obk.de> | 2022-07-07 10:46:22 +0000 |
|---|---|---|
| committer | Oli Scherer <git-spam-no-reply9815368754983@oli-obk.de> | 2022-07-07 10:46:22 +0000 |
| commit | 2a899dc1cfe37270cf976b54a2953133faafa0ae (patch) | |
| tree | 25a59ae0560ff4d4d2490f4985e9424051fb871a /src/test/ui/layout | |
| parent | e78e747f53c36e53ff99c94438d2efa26830fc4b (diff) | |
`UnsafeCell` now has no niches, ever.
Diffstat (limited to 'src/test/ui/layout')
| -rw-r--r-- | src/test/ui/layout/unsafe-cell-hides-niche.rs | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/test/ui/layout/unsafe-cell-hides-niche.rs b/src/test/ui/layout/unsafe-cell-hides-niche.rs index 4ca3f7a1aad..eb65756a5f6 100644 --- a/src/test/ui/layout/unsafe-cell-hides-niche.rs +++ b/src/test/ui/layout/unsafe-cell-hides-niche.rs @@ -5,8 +5,6 @@ // run-pass -#![feature(no_niche)] - use std::cell::UnsafeCell; use std::mem::size_of; use std::num::NonZeroU32 as N32; @@ -16,8 +14,7 @@ struct Wrapper<T>(T); #[repr(transparent)] struct Transparent<T>(T); -#[repr(no_niche)] -struct NoNiche<T>(T); +struct NoNiche<T>(UnsafeCell<T>); fn main() { assert_eq!(size_of::<Option<Wrapper<u32>>>(), 8); |
