Expand description
Zero-cost conversion functions for valence_nbt
.
While working with Value
, it is often necessary to convert between
collections of signed and unsigned integer types due to API
differences. For instance, you may be given a &[i8]
from
Value::ByteArray
, but functions like Write::write_all
expect to
receive a &[u8]
.
This module provides functions to perform conversions between these types
with zero-cost and no unsafe
code on your part.
Functionsยง
- Converts a
&[i8]
into a&[u8]
. - Converts a
Vec<i8>
into aVec<u8>
without cloning. - Converts a
&[u8]
into a&[i8]
. - Converts a
Vec<u8>
into aVec<i8>
without cloning.