File tree Expand file tree Collapse file tree 2 files changed +1
-3
lines changed Expand file tree Collapse file tree 2 files changed +1
-3
lines changed Original file line number Diff line number Diff line change @@ -352,7 +352,7 @@ impl CString {
352352 /// # Safety
353353 ///
354354 /// This should only ever be called with a pointer that was earlier
355- /// obtained by calling [`CString::into_raw`] and this pointer must not be accessed
355+ /// obtained by calling [`CString::into_raw`] and the memory it points to must not be accessed
356356 /// through any other pointer during the lifetime of reconstructed `CString`.
357357 /// Other usage (e.g., trying to take ownership of a string that was allocated by foreign code)
358358 /// is likely to lead to undefined behavior or allocator corruption.
Original file line number Diff line number Diff line change @@ -608,8 +608,6 @@ impl str {
608608///
609609/// * The provided bytes must contain a valid UTF-8 sequence.
610610///
611- /// * The `Box<[u8]>` must have been allocated via the global allocator.
612- ///
613611/// # Examples
614612///
615613/// ```
You can’t perform that action at this time.
0 commit comments