MCPcopy Create free account
hub / github.com/PerroEngine/Perro / as_slice

Method as_slice

perro_source/core/perro_structs/src/structs/matrix/mod.rs:872–875  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

870
871 #[inline]
872 pub fn as_slice(&self) -> &[T] {
873 // SAFETY: nested arrays are contiguous and contain exactly ROWS * COLS elements.
874 unsafe { std::slice::from_raw_parts(self.0.as_ptr().cast(), ROWS * COLS) }
875 }
876
877 #[inline]
878 pub fn as_mut_slice(&mut self) -> &mut [T] {

Callers 15

edit_selected_transformFunction · 0.45
struct_fieldsMethod · 0.45
resolve_defs_in_moduleFunction · 0.45
resolve_defs_globalFunction · 0.45
candidate_rowsMethod · 0.45
matrix_slice_sumFunction · 0.45
get_flat_uncheckedMethod · 0.45
iterMethod · 0.45
cellsMethod · 0.45

Calls

no outgoing calls