let out = serialize_with_flavor(&message, AllocVec::new());
That method returns the inner Vec.
It should be great to be able to re-use an existing AllocVec to avoid repeated allocations when serializing a bunch of types. All we'd need is a
impl From<Vec<u8>> for AllocVec {
fn from(vec: Vec<u8>) -> Self {
Self(vec)
}
}
Would that make sense ?
That method returns the inner
Vec.It should be great to be able to re-use an existing
AllocVecto avoid repeated allocations when serializing a bunch of types. All we'd need is aWould that make sense ?