Inline the default implementation of approx_eq
This commit is contained in:
parent
f5b0b76d8d
commit
1672e9e5d2
|
@ -9,6 +9,7 @@ pub trait ApproxEq<Eps> {
|
|||
fn approx_eq_eps(a: &Self, other: &Self, epsilon: &Eps) -> bool;
|
||||
|
||||
/// Tests approximate equality.
|
||||
#[inline]
|
||||
fn approx_eq(a: &Self, b: &Self) -> bool {
|
||||
ApproxEq::approx_eq_eps(a, b, &ApproxEq::approx_epsilon(None::<Self>))
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue