I want to indicate in the debug representation that a field contains Vec or slice and give a preview of what sort of data it contains without showing the whole slice. I propose an option like so
#[derivative(Debug=take(10))]
field: Vec<u8>
which translates to whatever the debug formatting of the following is
field.iter().take(10).collect::Vec<_>()
I'm happy to make a PR if this is something you're open to.
I want to indicate in the debug representation that a field contains Vec or slice and give a preview of what sort of data it contains without showing the whole slice. I propose an option like so
which translates to whatever the debug formatting of the following is
I'm happy to make a PR if this is something you're open to.