pub fn to_vec<T: ?Sized>(value: &T) -> Result<Vec<u8>, Error> where
Serialize the given data structure as a TOML byte vector.
Serialization can fail if
T's implementation of
Serialize decides to
T contains a map with non-string keys, or if
T attempts to
serialize an unsupported datatype such as an enum, tuple, or tuple struct.