Expand description
§null-terminated-str
Provides null terminated utf-8 str NullTerminatedStr (borrowed) and
NullTerminatedString (owned) that is compatible with
std::ffi::CStrstd::ffi::CStringstrString
Also provides const_null_terminated_str! to create NullTerminatedStr
at compile time and IntoNullTerminatedString that accepts &str,
String, &NullTerminatedStr and NullTerminatedString to avoid
frequent allocation in FFI call.
Macros§
- const_
null_ terminated_ str - Create a null-terminated utf-8 str as an rvalue. Appends a NUL byte to the passed string.