Skip to content

Commit

Permalink
Improve ccmath support detection.
Browse files Browse the repository at this point in the history
See discussion in #1045.
  • Loading branch information
jzmaddock committed Nov 5, 2023
1 parent 11e2348 commit d7048ec
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions include/boost/math/ccmath/detail/config.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,28 @@
#include <boost/math/tools/is_standalone.hpp>

#ifndef BOOST_MATH_STANDALONE

#include <boost/config.hpp>
#ifdef BOOST_NO_CXX17_IF_CONSTEXPR
# define BOOST_MATH_NO_CCMATH
#endif

#else // BOOST_MATH_STANDALONE

#if defined(_MSC_VER)

#if defined(_MSVC_LANG) && (_MSVC_LANG < 201703)
# define BOOST_MATH_NO_CCMATH
#endif

#else // _MSC_VER

#if (__cplusplus < 201703)
# define BOOST_MATH_NO_CCMATH
#endif

#endif

#endif

#ifndef _MSC_VER
Expand Down

0 comments on commit d7048ec

Please sign in to comment.