pub struct SliceSpec {
pub start: isize,
pub end: isize,
pub step: isize,
}Expand description
Explicit slice descriptor.
A zero step is invalid. Layout metadata APIs support signed steps when reachable-range validation proves the view stays inside the backing allocation.
§Examples
use tenferro_tensor_core::SliceSpec;
let spec = SliceSpec { start: 1, end: 4, step: 2 };
assert_eq!(spec.step, 2);Fields§
§start: isize§end: isize§step: isizeTrait Implementations§
impl Copy for SliceSpec
impl Eq for SliceSpec
impl StructuralPartialEq for SliceSpec
Auto Trait Implementations§
impl Freeze for SliceSpec
impl RefUnwindSafe for SliceSpec
impl Send for SliceSpec
impl Sync for SliceSpec
impl Unpin for SliceSpec
impl UnsafeUnpin for SliceSpec
impl UnwindSafe for SliceSpec
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