Fix MSVC C4668 in throw_exception.hpp

Fix MSVC C4668 warnings (undefined preprocessor macro) for __GNUC__ and __GNUC_MINOR__ by checking if __GNUC__ is defined first.
This commit is contained in:
Peter Kolbus
2018-03-26 22:38:33 -05:00
committed by GitHub
parent 56d65d5f62
commit f5022b5ca8

View File

@ -3,7 +3,7 @@
#include <boost/config.hpp> #include <boost/config.hpp>
#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) #if defined(__GNUC__) && (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
#pragma GCC system_header #pragma GCC system_header
#endif #endif
#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS) #if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)