Skip to content

Commit 72b110a

Browse files
committed
Stabilize select_unpredictable
FCP completed in tracking issue #133962.
1 parent 6e23095 commit 72b110a

File tree

3 files changed

+1
-5
lines changed

3 files changed

+1
-5
lines changed

library/core/src/hint.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -763,8 +763,6 @@ pub const fn cold_path() {
763763
///
764764
/// Distribute values evenly between two buckets:
765765
/// ```
766-
/// #![feature(select_unpredictable)]
767-
///
768766
/// use std::hash::BuildHasher;
769767
/// use std::hint;
770768
///
@@ -780,7 +778,7 @@ pub const fn cold_path() {
780778
/// # assert_eq!(bucket_one.len() + bucket_two.len(), 1);
781779
/// ```
782780
#[inline(always)]
783-
#[unstable(feature = "select_unpredictable", issue = "133962")]
781+
#[stable(feature = "select_unpredictable", since = "CURRENT_RUSTC_VERSION")]
784782
pub fn select_unpredictable<T>(condition: bool, true_val: T, false_val: T) -> T {
785783
// FIXME(https://github.com/rust-lang/unsafe-code-guidelines/issues/245):
786784
// Change this to use ManuallyDrop instead.

library/coretests/tests/lib.rs

-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@
6868
#![feature(pointer_is_aligned_to)]
6969
#![feature(portable_simd)]
7070
#![feature(ptr_metadata)]
71-
#![feature(select_unpredictable)]
7271
#![feature(slice_from_ptr_range)]
7372
#![feature(slice_internals)]
7473
#![feature(slice_partition_dedup)]

tests/codegen/intrinsics/select_unpredictable.rs

-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
//@ compile-flags: -Copt-level=3 -Zmerge-functions=disabled
22

33
#![feature(core_intrinsics)]
4-
#![feature(select_unpredictable)]
54
#![crate_type = "lib"]
65

76
/* Test the intrinsic */

0 commit comments

Comments
 (0)