
17 Mar
2014
17 Mar
'14
6:29 p.m.
What does seem to work for MSVC compiling is adding (somewhat inelegant) definition: namespace std { boost::multiprecision::number<boost::multiprecision::backends::cpp_dec_float<80> > sqrt(const boost::multiprecision::number<boost::multiprecision::backends::cpp_dec_float<80> >& in) { boost::multiprecision::backends::cpp_dec_float<80> v = in.canonical_value(in); return v.calculate_sqrt( ); } }
But gcc 4.8.2 compiling produces:
If you do that, then you need to define the std::sqrt overload *before* any polygon library include, otherwise GCC is correct in not considering the overload as a candidate, and MSVC is wrong in finding it. John.