blob: b8e5ddb3234780df5096a6e3f7bfc1820dd25470 (
plain)
1
2
3
4
5
6
7
8
9
10
11
|
use std::marker::PhantomData;
use std::mem::MaybeUninit;
pub(crate) struct MakeMaybeUninit<T, const N: usize>(PhantomData<fn() -> T>);
impl<T, const N: usize> MakeMaybeUninit<T, N> {
pub(crate) const VALUE: MaybeUninit<T> = MaybeUninit::uninit();
pub(crate) const ARRAY: [MaybeUninit<T>; N] = [Self::VALUE; N];
}
|