pub fn set_preserving(
content: &str,
path: &str,
value: &Value,
) -> DocumentResult<String>Expand description
Edit an existing TOML item without reserializing the surrounding document.
Scalars, arrays, inline tables, and ordinary tables are supported. Existing collection nodes are updated in place so their outer decor, element/key decor, ordering, multiline layout, comments, and trailing-comma style stay attached to the target wherever the replacement still has a corresponding element or key. Arrays of tables remain deliberately unsupported because replacing one safely requires an explicit identity policy.