pub(super) enum MaybeKnown<T> {
Known(T),
Computed(Word),
}
Expand description
A value that we either know at translation time, or need to compute at runtime.
Variants§
Known(T)
The value is known at shader translation time.
Computed(Word)
The value is computed by the instruction with the given id.
Trait Implementations§
source§impl<T: Clone> Clone for MaybeKnown<T>
impl<T: Clone> Clone for MaybeKnown<T>
source§fn clone(&self) -> MaybeKnown<T>
fn clone(&self) -> MaybeKnown<T>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreimpl<T: Copy> Copy for MaybeKnown<T>
Auto Trait Implementations§
impl<T> Freeze for MaybeKnown<T>where
T: Freeze,
impl<T> RefUnwindSafe for MaybeKnown<T>where
T: RefUnwindSafe,
impl<T> Send for MaybeKnown<T>where
T: Send,
impl<T> Sync for MaybeKnown<T>where
T: Sync,
impl<T> Unpin for MaybeKnown<T>where
T: Unpin,
impl<T> UnwindSafe for MaybeKnown<T>where
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)