1use std::mem::MaybeUninit;
4
5use crate::Const;
6
7pub struct IntoSome<C>(C);
9impl<C: Const> Const for IntoSome<C> {
10 type Type = Option<C::Type>;
11 const VALUE: Self::Type = Some(C::VALUE);
12}
13
14pub struct UninitOf<T>(T);
16impl<T> Const for UninitOf<T> {
17 type Type = MaybeUninit<T>;
18 const VALUE: Self::Type = MaybeUninit::uninit();
19}
20
21pub struct IntoInit<C>(C);
23impl<C: Const> Const for IntoInit<C> {
24 type Type = MaybeUninit<C::Type>;
25 const VALUE: Self::Type = MaybeUninit::new(C::VALUE);
26}