mirror of
https://github.com/rust-lang/rust.git
synced 2025-01-11 07:21:51 +00:00
Fix doctests for slice::exact_chunks() for real
This commit is contained in:
parent
802ba9ea5b
commit
e51a89a0ad
@ -648,7 +648,7 @@ impl<T> [T] {
|
||||
/// #![feature(exact_chunks)]
|
||||
///
|
||||
/// let slice = ['l', 'o', 'r', 'e', 'm'];
|
||||
/// let mut iter = slice.chunks(2);
|
||||
/// let mut iter = slice.exact_chunks(2);
|
||||
/// assert_eq!(iter.next().unwrap(), &['l', 'o']);
|
||||
/// assert_eq!(iter.next().unwrap(), &['r', 'e']);
|
||||
/// assert!(iter.next().is_none());
|
||||
@ -711,7 +711,7 @@ impl<T> [T] {
|
||||
/// }
|
||||
/// count += 1;
|
||||
/// }
|
||||
/// assert_eq!(v, &[1, 1, 2, 2]);
|
||||
/// assert_eq!(v, &[1, 1, 2, 2, 0]);
|
||||
/// ```
|
||||
#[unstable(feature = "exact_chunks", issue = "47115")]
|
||||
#[inline]
|
||||
|
Loading…
Reference in New Issue
Block a user