News for hackers. Stuff that matters.
Re:String types in Rust by p0nce on Tuesday March 29, 2016 @06:16AM (#11380512)
> Rust cares about first-class FFI support; in particular, copying strings at FFI boundaries is right out. That is why Rust needs C strings to be a separate type.

How does Rust handle strings encoded as UTF-16 or UTF-32? Does it need immediate conversion?

Re:String types in Rust by fpoling on Tuesday March 29, 2016 @07:04AM (#11380649)
OsString [1] in Rust provides native string that can be directly passed to OS-specific API. It is UTF-16 on Windows.

[1] - https://doc.rust-lang.org/std/ffi/struct.OsString.html