diff --git a/include/boost/system/error_code.hpp b/include/boost/system/error_code.hpp index 7be7005..f40a99e 100644 --- a/include/boost/system/error_code.hpp +++ b/include/boost/system/error_code.hpp @@ -348,6 +348,12 @@ class generic_error_category: public error_category { public: + // clang++ 3.8 and below: initialization of const object + // requires a user-provided default constructor + BOOST_SYSTEM_CONSTEXPR generic_error_category() BOOST_SYSTEM_NOEXCEPT + { + } + const char * name() const BOOST_SYSTEM_NOEXCEPT { return "generic"; @@ -360,6 +366,10 @@ class system_error_category: public error_category { public: + BOOST_SYSTEM_CONSTEXPR system_error_category() BOOST_SYSTEM_NOEXCEPT + { + } + const char * name() const BOOST_SYSTEM_NOEXCEPT { return "system";