pub struct CastSubByteDescriptor {
pub numel: i32,
pub input_element: ElementKind,
pub output_element: ElementKind,
}Expand description
Descriptor for a sub-byte cast.
numel is the element count for both input and output (cast doesn’t
change shape). For S4 / U4 endpoints numel MUST be even — the
packed buffer is numel / 2 bytes, and odd numels would leave a
dangling half-byte.
input_element and output_element are the runtime dtype tags;
they must match TIn / TOut’s underlying width (the plan
cross-checks via sizeof::<T>() at select time).
Fields§
§numel: i32Number of elements in both input and output.
input_element: ElementKindInput element type.
output_element: ElementKindOutput element type.
Trait Implementations§
Source§impl Clone for CastSubByteDescriptor
impl Clone for CastSubByteDescriptor
Source§fn clone(&self) -> CastSubByteDescriptor
fn clone(&self) -> CastSubByteDescriptor
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for CastSubByteDescriptor
Auto Trait Implementations§
impl Freeze for CastSubByteDescriptor
impl RefUnwindSafe for CastSubByteDescriptor
impl Send for CastSubByteDescriptor
impl Sync for CastSubByteDescriptor
impl Unpin for CastSubByteDescriptor
impl UnsafeUnpin for CastSubByteDescriptor
impl UnwindSafe for CastSubByteDescriptor
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