diff options
Diffstat (limited to 'src/libcore/num/float.rs')
| -rw-r--r-- | src/libcore/num/float.rs | 21 |
1 files changed, 6 insertions, 15 deletions
diff --git a/src/libcore/num/float.rs b/src/libcore/num/float.rs index 496ad4ec176..da9d03f6a7b 100644 --- a/src/libcore/num/float.rs +++ b/src/libcore/num/float.rs @@ -20,12 +20,11 @@ // PORT this must match in width according to architecture -use from_str; use libc::c_int; use num::{Zero, One, strconv}; use prelude::*; -pub use f64::{add, sub, mul, quot, rem, lt, le, eq, ne, ge, gt}; +pub use f64::{add, sub, mul, div, rem, lt, le, eq, ne, ge, gt}; pub use f64::logarithm; pub use f64::{acos, asin, atan2, cbrt, ceil, copysign, cosh, floor}; pub use f64::{erf, erfc, exp, expm1, exp2, abs_sub}; @@ -289,7 +288,7 @@ pub fn from_str_radix(num: &str, radix: uint) -> Option<float> { strconv::ExpNone, false, false) } -impl from_str::FromStr for float { +impl FromStr for float { #[inline(always)] fn from_str(val: &str) -> Option<float> { from_str(val) } } @@ -691,11 +690,13 @@ impl Mul<float,float> for float { #[inline(always)] fn mul(&self, other: &float) -> float { *self * *other } } + #[cfg(notest)] -impl Quot<float,float> for float { +impl Div<float,float> for float { #[inline(always)] - fn quot(&self, other: &float) -> float { *self / *other } + fn div(&self, other: &float) -> float { *self / *other } } + #[cfg(notest)] impl Rem<float,float> for float { #[inline(always)] @@ -1132,13 +1133,3 @@ mod tests { assert_eq!(to_str_digits(-infinity, 10u), ~"-inf"); } } - -// -// Local Variables: -// mode: rust -// fill-column: 78; -// indent-tabs-mode: nil -// c-basic-offset: 4 -// buffer-file-coding-system: utf-8-unix -// End: -// |
