pub fn decode_mut<T: Ord>(xs: &mut [T], p: usize)Expand description
Applies the permutation of the value p to the slice xs.
The applied permutation can be encoded with encode to get back p.
decode_mut(&mut xs, p);
assert_eq!(encode(&xs), p);See decode for a version that allocates a vector for the permutation.
ยงPanics
Panics in debug mode if xs is not increasing or p is out of range.