Module debug

Module debug 

Source
Expand description

New functions for &(mut) dyn [Debug].

§Example

let array: [u8; 4] = [1, 2, 4, 8];
let slice = debug::new(&array);

assert_eq!(
    format!("{slice:?}"),
    "[1, 2, 4, 8]",
);

Functions§

new
Create a dyn slice from a slice of a type that implements Debug.
new_mut
Create a mutable dyn slice from a mutable slice of a type that implements Debug.

Type Aliases§

Dyn
An alias for dyn Debug.
Slice
An alias for &dyn [Debug] (DynSlice<Dyn>).
SliceMut
An alias for &mut dyn [Debug] (DynSliceMut<Dyn>).