Closed Lastique closed 1 year ago
And the same issue is with gcc-4.6:
./boost/test/utils/runtime/errors.hpp:42:5: error: function 'boost::runtime::param_error::~param_error()' defaulted on its first declaration must not have an exception-specification
./boost/test/utils/runtime/errors.hpp:61:5: error: function 'boost::runtime::init_error::~init_error()' defaulted on its first declaration must not have an exception-specification
./boost/test/utils/runtime/errors.hpp:67:5: error: function 'boost::runtime::input_error::~input_error()' defaulted on its first declaration must not have an exception-specification
./boost/test/utils/runtime/errors.hpp:76:5: error: function 'boost::runtime::specific_param_error<Derived, Base>::~specific_param_error()' defaulted on its first declaration must not have an exception-specification
./boost/test/utils/runtime/errors.hpp:169:5: error: function 'boost::runtime::ambiguous_param::~ambiguous_param()' defaulted on its first declaration must not have an exception-specification
./boost/test/utils/runtime/errors.hpp:185:5: error: function 'boost::runtime::unrecognized_param::~unrecognized_param()' defaulted on its first declaration must not have an exception-specification
"g++-4.6" -ftemplate-depth-1024 -std=c++0x -fvisibility-inlines-hidden -fPIC -m64 -pthread -O0 -fno-inline -Wall -g -fvisibility=hidden -Wno-variadic-macros -DBOOST_ALL_NO_LIB=1 -DBOOST_TEST_DYN_LINK=1 -I"." -c -o "bin.v2/libs/test/build/gcc-4.6/debug/cxxstd-0x-iso/threading-multi/visibility-hidden/compiler_log_formatter.o" "libs/test/src/compiler_log_formatter.cpp"
Ugh, sorry. I can't see an elegant (one-line) fix; would a multi-line compatibility change be OK? Something like
#ifdef BOOST_NO_CXX11
~param_error() BOOST_NOEXCEPT_OR_NOTHROW BOOST_OVERRIDE {}
#else
~param_error() noexcept override = default;
#endif
If so (or if you can suggest any other mechanism) I'll prepare a PR.
Ugh, sorry. I can't see an elegant (one-line) fix; would a multi-line compatibility change be OK? Something like
#ifdef BOOST_NO_CXX11 ~param_error() BOOST_NOEXCEPT_OR_NOTHROW BOOST_OVERRIDE {} #else ~param_error() noexcept override = default; #endif
If so (or if you can suggest any other mechanism) I'll prepare a PR.
That looks fine to me, and a PR would be great. Thanks.
Ugh, sorry. I can't see an elegant (one-line) fix; would a multi-line compatibility change be OK? Something like
#ifdef BOOST_NO_CXX11 ~param_error() BOOST_NOEXCEPT_OR_NOTHROW BOOST_OVERRIDE {} #else ~param_error() noexcept override = default; #endif
If so (or if you can suggest any other mechanism) I'll prepare a PR.
You could define your own compatibility macro like BOOST_DEFAULTED_FUNCTION
, which expands to func() = default
only on compilers that fully support the use cases you need. That is, on gcc >= 4.7 and MSVC >= 14.0. Then the rest of the changes would be more clean.
It seems, https://github.com/boostorg/test/pull/375 broke compilation on MSVC-12, as seen in Boost.Log CI.
CC @ecatmur.