pub fn write_shaped<T: Shaped>(
out: &mut Vec<u8>,
catalog: &Catalog,
ty: &Type,
value: &T,
) -> Result<(), EncodeError>Expand description
Appends value’s encoding at ty in catalog to out.
§Errors
An EncodeError when ty is not the type T’s form projects to, or
the value is out of a form its type holds it to; out then holds
whatever was written before the error.