diff options
| author | Russell Mackenzie <russmackdev@gmail.com> | 2017-03-19 01:39:11 +0000 |
|---|---|---|
| committer | Russell Mackenzie <russmackdev@gmail.com> | 2017-03-19 01:41:44 +0000 |
| commit | b77d31ac61d1772ccfab6f37cb19559adc843466 (patch) | |
| tree | ea44b73dd317e795332b68b2229d753e7cd1cb43 | |
| parent | 4853584000c2e71710318b1ff3393b6be25c076a (diff) | |
| download | rust-b77d31ac61d1772ccfab6f37cb19559adc843466.tar.gz rust-b77d31ac61d1772ccfab6f37cb19559adc843466.zip | |
Add mention of None as possible return. Closes #40435.
| -rw-r--r-- | src/libcollections/slice.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libcollections/slice.rs b/src/libcollections/slice.rs index 11fc1d553f2..8147b83cf04 100644 --- a/src/libcollections/slice.rs +++ b/src/libcollections/slice.rs @@ -230,7 +230,7 @@ impl<T> [T] { core_slice::SliceExt::first_mut(self) } - /// Returns the first and all the rest of the elements of a slice. + /// Returns the first and all the rest of the elements of a slice, or `None` if it is empty. /// /// # Examples /// @@ -248,7 +248,7 @@ impl<T> [T] { core_slice::SliceExt::split_first(self) } - /// Returns the first and all the rest of the elements of a slice. + /// Returns the first and all the rest of the elements of a slice, or `None` if it is empty. /// /// # Examples /// @@ -268,7 +268,7 @@ impl<T> [T] { core_slice::SliceExt::split_first_mut(self) } - /// Returns the last and all the rest of the elements of a slice. + /// Returns the last and all the rest of the elements of a slice, or `None` if it is empty. /// /// # Examples /// @@ -287,7 +287,7 @@ impl<T> [T] { } - /// Returns the last and all the rest of the elements of a slice. + /// Returns the last and all the rest of the elements of a slice, or `None` if it is empty. /// /// # Examples /// |
