Expand description
Indexing implementations for [T].
Re-exportsยง
use crate::intrinsics::slice_get_unchecked;๐Experimental use crate::marker::Destruct;๐Experimental use crate::panic::const_panic;๐Experimental use crate::ub_checks::assert_unsafe_precondition;๐Experimental use crate::ops;๐use crate::range;๐
Enumsยง
- Range
Error ๐
Traitsยง
- Slice
Index - A helper trait used for indexing operations.
Functionsยง
- get_
offset_ ๐ โlen_ mut_ noubcheck - get_
offset_ ๐ โlen_ noubcheck - into_
range_ ๐unchecked - Converts a pair of
ops::Bounds intoops::Rangewithout performing any bounds checking or (in debug) overflow checking. - into_
slice_ ๐range - Converts pair of
ops::Bounds intoops::Range. Panics on overflowing indices. - slice_
index_ ๐fail - try_
into_ ๐slice_ range - Converts pair of
ops::Bounds intoops::Range. ReturnsNoneon overflowing indices. - range
Experimental - Performs bounds checking of a range.
- try_
range Experimental - Performs bounds checking of a range without panicking.