Enum krnl_core::scalar::ScalarType
source · #[non_exhaustive]pub enum ScalarType {
U8 = 1,
I8 = 2,
U16 = 3,
I16 = 4,
F16 = 5,
BF16 = 6,
U32 = 7,
I32 = 8,
F32 = 9,
U64 = 10,
I64 = 11,
F64 = 12,
}
Expand description
Numerical types supported in krnl.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Implementations§
Trait Implementations§
source§impl Clone for ScalarType
impl Clone for ScalarType
source§fn clone(&self) -> ScalarType
fn clone(&self) -> ScalarType
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 moresource§impl Debug for ScalarType
impl Debug for ScalarType
source§impl<'de> Deserialize<'de> for ScalarType
Available on crate feature serde
only.
impl<'de> Deserialize<'de> for ScalarType
Available on crate feature
serde
only.source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Display for ScalarType
impl Display for ScalarType
source§impl From<ScalarType> for u32
impl From<ScalarType> for u32
source§fn from(scalar_type: ScalarType) -> u32
fn from(scalar_type: ScalarType) -> u32
Converts to this type from the input type.
source§impl FromStr for ScalarType
Available on non-target_arch="spirv"
only.
impl FromStr for ScalarType
Available on non-
target_arch="spirv"
only.source§impl Hash for ScalarType
impl Hash for ScalarType
source§impl PartialEq for ScalarType
impl PartialEq for ScalarType
source§fn eq(&self, other: &ScalarType) -> bool
fn eq(&self, other: &ScalarType) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for ScalarType
Available on crate feature serde
only.
impl Serialize for ScalarType
Available on crate feature
serde
only.source§impl TryFrom<u32> for ScalarType
impl TryFrom<u32> for ScalarType
impl Copy for ScalarType
impl Eq for ScalarType
impl StructuralPartialEq for ScalarType
Auto Trait Implementations§
impl Freeze for ScalarType
impl RefUnwindSafe for ScalarType
impl Send for ScalarType
impl Sync for ScalarType
impl Unpin for ScalarType
impl UnwindSafe for ScalarType
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