Skip to content

Commit 3ae0dab

Browse files
committed
Bless a few tests
1 parent 06a1c14 commit 3ae0dab

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

library/alloc/src/vec/mod.rs

-3
Original file line numberDiff line numberDiff line change
@@ -3009,22 +3009,19 @@ impl<T, A: Allocator, const N: usize> TryFrom<Vec<T, A>> for [T; N] {
30093009
/// # Examples
30103010
///
30113011
/// ```
3012-
/// use std::convert::TryInto;
30133012
/// assert_eq!(vec![1, 2, 3].try_into(), Ok([1, 2, 3]));
30143013
/// assert_eq!(<Vec<i32>>::new().try_into(), Ok([]));
30153014
/// ```
30163015
///
30173016
/// If the length doesn't match, the input comes back in `Err`:
30183017
/// ```
3019-
/// use std::convert::TryInto;
30203018
/// let r: Result<[i32; 4], _> = (0..10).collect::<Vec<_>>().try_into();
30213019
/// assert_eq!(r, Err(vec![0, 1, 2, 3, 4, 5, 6, 7, 8, 9]));
30223020
/// ```
30233021
///
30243022
/// If you're fine with just getting a prefix of the `Vec<T>`,
30253023
/// you can call [`.truncate(N)`](Vec::truncate) first.
30263024
/// ```
3027-
/// use std::convert::TryInto;
30283025
/// let mut v = String::from("hello world").into_bytes();
30293026
/// v.sort();
30303027
/// v.truncate(2);

0 commit comments

Comments
 (0)