Function try_copy
pub(crate) fn try_copy(bytes: &[u8]) -> Result<Vec<u8>, TryReserveError>Available on crate feature
alloc only.Expand description
Copies bytes into a new Vec without panicking if the allocation fails.
pub(crate) fn try_copy(bytes: &[u8]) -> Result<Vec<u8>, TryReserveError>alloc only.Copies bytes into a new Vec without panicking if the allocation fails.