From 8460dac909fc10b6bf0216d0123735c283cc1391 Mon Sep 17 00:00:00 2001 From: Huon Wilson Date: Tue, 6 Aug 2013 22:19:33 +1000 Subject: [PATCH] std: add missing #[inline] annotation to the f64 arithmetic trait impls. --- src/libstd/num/f64.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/libstd/num/f64.rs b/src/libstd/num/f64.rs index c7db60e6fd2..60527905779 100644 --- a/src/libstd/num/f64.rs +++ b/src/libstd/num/f64.rs @@ -278,18 +278,22 @@ fn one() -> f64 { 1.0 } #[cfg(not(test))] impl Add for f64 { + #[inline] fn add(&self, other: &f64) -> f64 { *self + *other } } #[cfg(not(test))] impl Sub for f64 { + #[inline] fn sub(&self, other: &f64) -> f64 { *self - *other } } #[cfg(not(test))] impl Mul for f64 { + #[inline] fn mul(&self, other: &f64) -> f64 { *self * *other } } #[cfg(not(test))] impl Div for f64 { + #[inline] fn div(&self, other: &f64) -> f64 { *self / *other } } #[cfg(not(test))] -- 2.44.0