multiversx_sc_codec

Function dep_decode_from_byte_slice

Source
pub fn dep_decode_from_byte_slice<T, H>(
    input: &[u8],
    h: H,
) -> Result<T, H::HandledErr>
Expand description

Convenience method, to avoid having to specify type when calling dep_decode. Especially useful in the macros. Also checks that the entire slice was used. The input doesn’t need to be mutable because we are not changing the underlying data.