From bd68de89b55d7f7d7adc41fdcd0a5bac1f805692 Mon Sep 17 00:00:00 2001 From: Pyry Kontio Date: Tue, 26 May 2020 02:48:56 +0900 Subject: [PATCH] remove unneeded and unidiomatic must_use --- src/libcore/num/f32.rs | 1 - src/libcore/num/f64.rs | 1 - 2 files changed, 2 deletions(-) diff --git a/src/libcore/num/f32.rs b/src/libcore/num/f32.rs index 813e3077c3b8..36b70587385c 100644 --- a/src/libcore/num/f32.rs +++ b/src/libcore/num/f32.rs @@ -851,7 +851,6 @@ impl f32 { /// # .zip([-5.0, 0.1, 10.0, 99.0, f32::INFINITY, f32::NAN].iter()) /// # .all(|(a, b)| a.to_bits() == b.to_bits())) /// ``` - #[must_use = "method returns a new number and does not mutate the original value"] #[unstable(feature = "total_cmp", issue = "none")] #[inline] pub fn total_cmp(&self, other: &Self) -> crate::cmp::Ordering { diff --git a/src/libcore/num/f64.rs b/src/libcore/num/f64.rs index 9c0218083801..61711df3c65e 100644 --- a/src/libcore/num/f64.rs +++ b/src/libcore/num/f64.rs @@ -865,7 +865,6 @@ impl f64 { /// # .zip([-5.0, 0.1, 10.0, 99.0, f64::INFINITY, f64::NAN].iter()) /// # .all(|(a, b)| a.to_bits() == b.to_bits())) /// ``` - #[must_use = "method returns a new number and does not mutate the original value"] #[unstable(feature = "total_cmp", issue = "none")] #[inline] pub fn total_cmp(&self, other: &Self) -> crate::cmp::Ordering {