Correct libm names
This commit is contained in:
parent
a76215965b
commit
03b46a940d
@ -8,9 +8,9 @@ This project adheres to [Semantic Versioning](http://semver.org/).
|
||||
### Added
|
||||
|
||||
- minf
|
||||
- min
|
||||
- maxf
|
||||
- max
|
||||
- fmin
|
||||
- fmaxf
|
||||
- fmax
|
||||
|
||||
## [v0.1.2] - 2018-07-18
|
||||
|
||||
|
@ -334,12 +334,12 @@ impl F32Ext for f32 {
|
||||
|
||||
#[inline]
|
||||
fn min(self, other: Self) -> Self {
|
||||
minf(self, other)
|
||||
fminf(self, other)
|
||||
}
|
||||
|
||||
#[inline]
|
||||
fn max(self, other: Self) -> Self {
|
||||
maxf(self, other)
|
||||
fmaxf(self, other)
|
||||
}
|
||||
}
|
||||
|
||||
@ -622,12 +622,12 @@ impl F64Ext for f64 {
|
||||
|
||||
#[inline]
|
||||
fn min(self, other: Self) -> Self {
|
||||
min(self, other)
|
||||
fmin(self, other)
|
||||
}
|
||||
|
||||
#[inline]
|
||||
fn max(self, other: Self) -> Self {
|
||||
max(self, other)
|
||||
fmax(self, other)
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#[inline]
|
||||
#[cfg_attr(all(test, assert_no_panic), no_panic::no_panic)]
|
||||
pub fn max(x: f64, y: f64) -> f64 {
|
||||
pub fn fmax(x: f64, y: f64) -> f64 {
|
||||
// IEEE754 says: maxNum(x, y) is the canonicalized number y if x < y, x if y < x, the
|
||||
// canonicalized number if one operand is a number and the other a quiet NaN. Otherwise it
|
||||
// is either x or y, canonicalized (this means results might differ among implementations).
|
@ -1,6 +1,6 @@
|
||||
#[inline]
|
||||
#[cfg_attr(all(test, assert_no_panic), no_panic::no_panic)]
|
||||
pub fn maxf(x: f32, y: f32) -> f32 {
|
||||
pub fn fmaxf(x: f32, y: f32) -> f32 {
|
||||
// IEEE754 says: maxNum(x, y) is the canonicalized number y if x < y, x if y < x, the
|
||||
// canonicalized number if one operand is a number and the other a quiet NaN. Otherwise it
|
||||
// is either x or y, canonicalized (this means results might differ among implementations).
|
@ -1,6 +1,6 @@
|
||||
#[inline]
|
||||
#[cfg_attr(all(test, assert_no_panic), no_panic::no_panic)]
|
||||
pub fn min(x: f64, y: f64) -> f64 {
|
||||
pub fn fmin(x: f64, y: f64) -> f64 {
|
||||
// IEEE754 says: minNum(x, y) is the canonicalized number x if x < y, y if y < x, the
|
||||
// canonicalized number if one operand is a number and the other a quiet NaN. Otherwise it
|
||||
// is either x or y, canonicalized (this means results might differ among implementations).
|
@ -1,6 +1,6 @@
|
||||
#[inline]
|
||||
#[cfg_attr(all(test, assert_no_panic), no_panic::no_panic)]
|
||||
pub fn minf(x: f32, y: f32) -> f32 {
|
||||
pub fn fminf(x: f32, y: f32) -> f32 {
|
||||
// IEEE754 says: minNum(x, y) is the canonicalized number x if x < y, y if y < x, the
|
||||
// canonicalized number if one operand is a number and the other a quiet NaN. Otherwise it
|
||||
// is either x or y, canonicalized (this means results might differ among implementations).
|
@ -112,6 +112,10 @@ mod floor;
|
||||
mod floorf;
|
||||
mod fma;
|
||||
mod fmaf;
|
||||
mod fmax;
|
||||
mod fmaxf;
|
||||
mod fmin;
|
||||
mod fminf;
|
||||
mod fmod;
|
||||
mod fmodf;
|
||||
mod frexp;
|
||||
@ -140,10 +144,6 @@ mod log1pf;
|
||||
mod log2;
|
||||
mod log2f;
|
||||
mod logf;
|
||||
mod max;
|
||||
mod maxf;
|
||||
mod min;
|
||||
mod minf;
|
||||
mod modf;
|
||||
mod modff;
|
||||
mod pow;
|
||||
@ -216,6 +216,10 @@ pub use self::floor::floor;
|
||||
pub use self::floorf::floorf;
|
||||
pub use self::fma::fma;
|
||||
pub use self::fmaf::fmaf;
|
||||
pub use self::fmax::fmax;
|
||||
pub use self::fmaxf::fmaxf;
|
||||
pub use self::fmin::fmin;
|
||||
pub use self::fminf::fminf;
|
||||
pub use self::fmod::fmod;
|
||||
pub use self::fmodf::fmodf;
|
||||
pub use self::frexp::frexp;
|
||||
@ -250,10 +254,6 @@ pub use self::log1pf::log1pf;
|
||||
pub use self::log2::log2;
|
||||
pub use self::log2f::log2f;
|
||||
pub use self::logf::logf;
|
||||
pub use self::max::max;
|
||||
pub use self::maxf::maxf;
|
||||
pub use self::min::min;
|
||||
pub use self::minf::minf;
|
||||
pub use self::modf::modf;
|
||||
pub use self::modff::modff;
|
||||
pub use self::pow::pow;
|
||||
|
Loading…
x
Reference in New Issue
Block a user