pub fn to_writer<T, W>(w: W, value: &T) -> Result<(), Error>where T: Serialize, W: Write,
Serialize a type implementing Serialize to JSON5 and write it to the given writer.
Serialize
Fails if we can’t express T in JSON5 (e.g. we try to serialize an object key without an obvious string representation) or if there’s an error writing to the writer.
T