stabilize partition_point
This commit is contained in:
parent
de21cdf792
commit
afdc8c7918
@ -3425,8 +3425,6 @@ pub fn is_sorted_by_key<F, K>(&self, f: F) -> bool
|
|||||||
/// # Examples
|
/// # Examples
|
||||||
///
|
///
|
||||||
/// ```
|
/// ```
|
||||||
/// #![feature(partition_point)]
|
|
||||||
///
|
|
||||||
/// let v = [1, 2, 3, 3, 5, 6, 7];
|
/// let v = [1, 2, 3, 3, 5, 6, 7];
|
||||||
/// let i = v.partition_point(|&x| x < 5);
|
/// let i = v.partition_point(|&x| x < 5);
|
||||||
///
|
///
|
||||||
@ -3434,7 +3432,7 @@ pub fn is_sorted_by_key<F, K>(&self, f: F) -> bool
|
|||||||
/// assert!(v[..i].iter().all(|&x| x < 5));
|
/// assert!(v[..i].iter().all(|&x| x < 5));
|
||||||
/// assert!(v[i..].iter().all(|&x| !(x < 5)));
|
/// assert!(v[i..].iter().all(|&x| !(x < 5)));
|
||||||
/// ```
|
/// ```
|
||||||
#[unstable(feature = "partition_point", reason = "new API", issue = "73831")]
|
#[stable(feature = "partition_point", since = "1.52.0")]
|
||||||
pub fn partition_point<P>(&self, mut pred: P) -> usize
|
pub fn partition_point<P>(&self, mut pred: P) -> usize
|
||||||
where
|
where
|
||||||
P: FnMut(&T) -> bool,
|
P: FnMut(&T) -> bool,
|
||||||
|
@ -67,7 +67,6 @@
|
|||||||
#![feature(option_result_unwrap_unchecked)]
|
#![feature(option_result_unwrap_unchecked)]
|
||||||
#![feature(option_unwrap_none)]
|
#![feature(option_unwrap_none)]
|
||||||
#![feature(peekable_peek_mut)]
|
#![feature(peekable_peek_mut)]
|
||||||
#![feature(partition_point)]
|
|
||||||
#![feature(once_cell)]
|
#![feature(once_cell)]
|
||||||
#![feature(unsafe_block_in_unsafe_fn)]
|
#![feature(unsafe_block_in_unsafe_fn)]
|
||||||
#![feature(int_bits_const)]
|
#![feature(int_bits_const)]
|
||||||
|
Loading…
Reference in New Issue
Block a user