Skip to main content

encode_content

Function encode_content 

Source
fn encode_content(cmd: &CommandWriteEditorFileData) -> (Vec<u8>, bool)
Expand description

The file’s original encoding, BOM and line endings, so a non-UTF-8 file round-trips instead of being silently rewritten as UTF-8. Absent fields default to UTF-8. The bool is true when some character has no representation in that encoding.