Skip to content

Commit 1a32a68

Browse files
committed
Mention slice patterns
1 parent c5295ac commit 1a32a68

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/libstd/primitive_docs.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -482,8 +482,8 @@ mod prim_pointer { }
482482
/// an array. Indeed, this provides most of the API for working with arrays.
483483
/// Slices have a dynamic size and do not coerce to arrays.
484484
///
485-
/// There is no way to move elements out of an array. See [`mem::replace`][replace]
486-
/// for an alternative.
485+
/// You can move elements out of an array with a slice pattern. If you want
486+
/// one element, see [`mem::replace`][replace].
487487
///
488488
/// # Examples
489489
///

0 commit comments

Comments
 (0)