11 ms·
Rust has an abstraction for the system encoding: OsStr. Though I think most Rust programs just assert everything is UTF-8, the language goes to great lengths to
by TazeTSchnitzel 3y ago
Rust has an abstraction for the system encoding: OsStr. Though I think most Rust programs just assert everything is UTF-8, the language goes to great lengths to ensure it is possible, and not even particularly difficult, to write Rust code that can handle Windows's broken UTF-16, yet which isn't Windows-specific.
- Georgelemental 3y agoEh, the `OsStr` API has warts still, some parts are unstable (https://github.com/rust-lang/rust/issues/111544 https://github.com/rust-lang/rust/issues/111544).