From 9858d49b168d628496c3ed7488eb524fc7ccf2d4 Mon Sep 17 00:00:00 2001 From: Slanterns Date: Wed, 14 Aug 2024 18:28:40 +0800 Subject: [PATCH] stabilize `is_none_or` --- core/src/option.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/core/src/option.rs b/core/src/option.rs index 6c89c81018038..9c6819bc58f32 100644 --- a/core/src/option.rs +++ b/core/src/option.rs @@ -656,8 +656,6 @@ impl Option { /// # Examples /// /// ``` - /// #![feature(is_none_or)] - /// /// let x: Option = Some(2); /// assert_eq!(x.is_none_or(|x| x > 1), true); /// @@ -669,7 +667,7 @@ impl Option { /// ``` #[must_use] #[inline] - #[unstable(feature = "is_none_or", issue = "126383")] + #[stable(feature = "is_none_or", since = "CURRENT_RUSTC_VERSION")] pub fn is_none_or(self, f: impl FnOnce(T) -> bool) -> bool { match self { None => true,