[][src]Function toml::ser::to_vec

pub fn to_vec<T: ?Sized>(value: &T) -> Result<Vec<u8>, Error> where
    T: Serialize

Serialize the given data structure as a TOML byte vector.

Serialization can fail if T's implementation of Serialize decides to fail, if 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.