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

Method as_mut_slice

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

Source from the content-addressed store, hash-verified

876
877 #[inline]
878 pub fn as_mut_slice(&mut self) -> &mut [T] {
879 // SAFETY: nested arrays are contiguous and contain exactly ROWS * COLS elements.
880 unsafe { std::slice::from_raw_parts_mut(self.0.as_mut_ptr().cast(), ROWS * COLS) }
881 }
882
883 /// Build from row-major flat slice.
884 ///

Callers 15

iter_mutMethod · 0.80
cells_mutMethod · 0.80
fillMethod · 0.80
copy_from_sliceMethod · 0.80
copy_fromMethod · 0.80
clone_from_matrixMethod · 0.80
swap_cellsMethod · 0.80
swap_flatMethod · 0.80
add_assign_f32Method · 0.80
sub_assign_f32Method · 0.80

Calls

no outgoing calls