std::vec::bytes: remove the reference to overlapping src and dest in

docs for copy_memory.

&mut [u8] and &[u8] really shouldn't be overlapping at all (part of the
uniqueness/aliasing guarantee of &mut), so no point in encouraging it.
This commit is contained in:
Huon Wilson 2013-12-17 00:06:13 +11:00
parent d0ae820765
commit 5c147cc408

View file

@ -2350,13 +2350,10 @@ pub mod bytes {
}
}
/**
* Copies data from one vector to another.
*
* Copies `src` to `dst`. The source and destination may
* overlap. Fails if the length of `dst` is less than the length
* of `src`.
*/
/// Copies data from one vector to another.
///
/// Copies `src` to `dst`. Fails if the length of `dst` is less
/// than the length of `src`.
#[inline]
pub fn copy_memory(dst: &mut [u8], src: &[u8]) {
// Bound checks are done at .copy_memory.