diff --git a/include/boost/system/detail/error_code.hpp b/include/boost/system/detail/error_code.hpp index 2b387fb..b8833b3 100644 --- a/include/boost/system/detail/error_code.hpp +++ b/include/boost/system/detail/error_code.hpp @@ -335,30 +335,11 @@ public: } } -#if !defined(BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS) - BOOST_SYSTEM_CONSTEXPR explicit operator bool() const BOOST_NOEXCEPT // true if error { return failed(); } -#else - - typedef void (*unspecified_bool_type)(); - static void unspecified_bool_true() {} - - BOOST_SYSTEM_CONSTEXPR operator unspecified_bool_type() const BOOST_NOEXCEPT // true if error - { - return failed()? unspecified_bool_true: 0; - } - - BOOST_SYSTEM_CONSTEXPR bool operator!() const BOOST_NOEXCEPT // true if no error - { - return !failed(); - } - -#endif - bool has_location() const BOOST_NOEXCEPT { return lc_flags_ >= 4; diff --git a/include/boost/system/detail/error_condition.hpp b/include/boost/system/detail/error_condition.hpp index b2da281..a53b4d9 100644 --- a/include/boost/system/detail/error_condition.hpp +++ b/include/boost/system/detail/error_condition.hpp @@ -158,30 +158,11 @@ public: } } -#if !defined(BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS) - BOOST_SYSTEM_CONSTEXPR explicit operator bool() const BOOST_NOEXCEPT // true if error { return failed(); } -#else - - typedef void (*unspecified_bool_type)(); - static void unspecified_bool_true() {} - - BOOST_SYSTEM_CONSTEXPR operator unspecified_bool_type() const BOOST_NOEXCEPT // true if error - { - return failed()? unspecified_bool_true: 0; - } - - BOOST_SYSTEM_CONSTEXPR bool operator!() const BOOST_NOEXCEPT // true if no error - { - return !failed(); - } - -#endif - // relationals: // the more symmetrical non-member syntax allows enum // conversions work for both rhs and lhs.