pub struct ConstToken<T, N>(/* private fields */);
Expand description
Workaround for const fn
limitations.
Some const fn
s in this crate will need an instance of this type
for some type-level information usually provided by traits.
A token can be obtained from BitFlags::CONST_TOKEN
. The relevant types
should be readily inferred from context.
For an example of usage, see not_c
.
Auto Trait Implementations§
impl<T, N> Freeze for ConstToken<T, N>where
N: Freeze,
impl<T, N> RefUnwindSafe for ConstToken<T, N>where
N: RefUnwindSafe,
T: RefUnwindSafe,
impl<T, N> Send for ConstToken<T, N>
impl<T, N> Sync for ConstToken<T, N>
impl<T, N> Unpin for ConstToken<T, N>
impl<T, N> UnwindSafe for ConstToken<T, N>where
N: UnwindSafe,
T: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more