pub fn from_slice<'de, T>(s: &'de [u8]) -> Result<T, Error>where
T: Deserialize<'de>,
Expand description
Deserializes bytes into a type.
This function will attempt to interpret s
as a TOML document and
deserialize T
from the document.
To deserializes TOML values, instead of documents, see ValueDeserializer
.