Skip to content

Commit 168ad44

Browse files
Fixed issue with usage of generics and moved feature gate to crate root
1 parent 6d1bc55 commit 168ad44

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

library/core/src/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,7 @@
141141
#![feature(unchecked_shifts)]
142142
#![feature(utf16_extra)]
143143
#![feature(variant_count)]
144+
#![feature(control_flow_into_value)]
144145
// tidy-alphabetical-end
145146
//
146147
// Language features:

library/core/src/ops/control_flow.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
#![feature(control_flow_into_value)]
21
use crate::{convert, ops};
32

43
/// Used to tell an operation whether it should exit early or go on as usual.
@@ -242,7 +241,7 @@ impl<T> ControlFlow<T, T> {
242241
/// assert_eq!(ControlFlow::<i32, i32>::Continue(512).into_value(), 512);
243242
/// ```
244243
#[unstable(feature = "control_flow_into_value", issue = "137461")]
245-
pub const fn into_value<T>(self) -> T {
244+
pub const fn into_value(self) -> T {
246245
match self {
247246
ControlFlow::Continue(x) | ControlFlow::Break(x) => x,
248247
}

0 commit comments

Comments
 (0)