diff --git a/src/func.cc b/src/func.cc index 6001475f..f96157f0 100644 --- a/src/func.cc +++ b/src/func.cc @@ -646,11 +646,11 @@ Value builtin_cross(const Context *, const EvalContext *evalctx) } double d0 = v0[a].toDouble(); double d1 = v1[a].toDouble(); - if (isnan(d0) || isnan(d1)) { + if (boost::math::isnan(d0) || boost::math::isnan(d1)) { PRINT("WARNING: Invalid value (NaN) in parameter vector for cross()"); return Value(); } - if (isinf(d0) || isinf(d1)) { + if (boost::math::isinf(d0) || boost::math::isinf(d1)) { PRINT("WARNING: Invalid value (INF) in parameter vector for cross()"); return Value(); } diff --git a/src/primitives.cc b/src/primitives.cc index cebc0314..f3c66fcd 100644 --- a/src/primitives.cc +++ b/src/primitives.cc @@ -42,7 +42,7 @@ using namespace boost::assign; // bring 'operator+=()' into scope #include -using boost::math::isinf; +#define isinf boost::math::isinf #define F_MINIMUM 0.01 diff --git a/src/value.cc b/src/value.cc index af2a4b42..00249cc0 100644 --- a/src/value.cc +++ b/src/value.cc @@ -40,8 +40,6 @@ #include #include -using boost::math::isnan; -using boost::math::isinf; std::ostream &operator<<(std::ostream &stream, const Filename &filename) { @@ -646,11 +644,11 @@ void Value::RangeType::normalize() { } uint32_t Value::RangeType::nbsteps() const { - if (isnan(step_val) || isinf(begin_val) || (isinf(end_val))) { + if (boost::math::isnan(step_val) || boost::math::isinf(begin_val) || (boost::math::isinf(end_val))) { return std::numeric_limits::max(); } - if ((begin_val == end_val) || isinf(step_val)) { + if ((begin_val == end_val) || boost::math::isinf(step_val)) { return 0; }