to_string

Function to_string 

Source
pub unsafe fn to_string(ptr: *const c_char) -> String
Expand description

ยงSafety

  • Passing a NULL pointer is allowed and will return an empty String.

  • When ptr is non-NULL, the pointed memory must respect the same constraints as a memory buffer passed to std::ffi::CStr::from_ptr.