Add `double` version of close_enough

This commit is contained in:
Jack Andersen 2018-02-09 20:25:31 -10:00
parent f82efe0583
commit 26ea606a09
1 changed files with 5 additions and 0 deletions

View File

@ -162,6 +162,11 @@ inline bool close_enough(float a, float b, double epsilon = 0.000009999999747378
{
return std::fabs(a - b) < epsilon;
}
inline bool close_enough(double a, double b, double epsilon = 0.000009999999747378752)
{
return std::fabs(a - b) < epsilon;
}
}
#endif // MATH_HPP