[][src]Function lastfm_parse_rs::lastfm_type::from_json_slice

pub fn from_json_slice<'de, Lt: LastfmType<'de>>(json: &'de [u8]) -> Result<Lt>

Parses given data type from json byte slice (zero-copy) Beware that it will fail in case source contains escape sequences, as serde is currently unable to decode them inplace. Current solution is to unescape input manually beforehand. See https://github.com/serde-rs/json/issues/318 and tests/common/mod.rs for more details.