Stabilize `duration_abs_diff`

This commit is contained in:
Ole Bertram 2024-06-29 20:39:13 +02:00
parent 19a1d2b404
commit 7f383d098a
No known key found for this signature in database
GPG Key ID: 5AE6943A31E36AEC
2 changed files with 3 additions and 3 deletions

View File

@ -620,13 +620,14 @@ impl Duration {
/// Basic usage:
///
/// ```
/// #![feature(duration_abs_diff)]
/// use std::time::Duration;
///
/// assert_eq!(Duration::new(100, 0).abs_diff(Duration::new(80, 0)), Duration::new(20, 0));
/// assert_eq!(Duration::new(100, 400_000_000).abs_diff(Duration::new(110, 0)), Duration::new(9, 600_000_000));
/// ```
#[unstable(feature = "duration_abs_diff", issue = "117618")]
#[stable(feature = "duration_abs_diff", since = "CURRENT_RUSTC_VERSION")]
#[rustc_const_stable(feature = "duration_abs_diff", since = "CURRENT_RUSTC_VERSION")]
#[rustc_allow_const_fn_unstable(const_option)]
#[must_use = "this returns the result of the operation, \
without modifying the original"]
#[inline]

View File

@ -30,7 +30,6 @@
#![feature(core_private_bignum)]
#![feature(core_private_diy_float)]
#![feature(dec2flt)]
#![feature(duration_abs_diff)]
#![feature(duration_consts_float)]
#![feature(duration_constants)]
#![feature(duration_constructors)]