We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e02d1eb commit ca66b81Copy full SHA for ca66b81
src/libstd/c_str.rs
@@ -277,9 +277,6 @@ impl<'self> ToCStr for &'self [u8] {
277
}
278
279
280
- /// WARNING: This function uses an optimization to only malloc a temporary
281
- /// CString when the source string is small. Do not save a reference to
282
- /// the `*libc::c_char` as it may be invalid after this function call.
283
fn with_c_str<T>(&self, f: &fn(*libc::c_char) -> T) -> T {
284
if self.len() < BUF_LEN {
285
do self.as_imm_buf |self_buf, self_len| {
0 commit comments