pub fn parse_move_datatype<T: MoveDatatype + for<'de> Deserialize<'de>>(
struct_tag: &StructTag,
bytes: &[u8],
) -> Result<(T::StructTag, T), FromRawDatatypeError>Available on crate feature
bcs only.Expand description
Parse an instance of a MoveDatatype from a generic struct tag and BCS bytes.
This function short-circuits if the type tag can’t be converted to the
MoveDatatype::StructTag, avoiding deserialization of the BCS bytes in such cases.