During the Rapperswil meeting the Library Working Group decided to revise the library in terms of no except. This paper presents proposed wording for some of these changes. The paper addresses National Body comments CH 16 and GB 60.
This paper poposes additional changes to those presented in N3148 and N3149. Changes in this paper are restricted to chapter 19 (diagnostics library).
Destructor should not throw and has been made noexcept.
Operators == and != for error categories cannot throw as they are specified to return pointer comparisons which cannot throw.
Functions for access to error category objects return a reference to a single objects. They have been specified as noexcept as they cannot throw.
Member function clear() is specified to establish the value and category pointer. None of those operations can throw. This paper proposes making clear() non-throwing.
Function make_error_code() is based on non-throwing operations. This paper proposes making it noexcept.
Member function clear() is specified to establish the value and category pointer. None of those operations can throw. This paper proposes making clear() non-throwing.
Function make_error_condition() is based on non-throwing operations. This paper proposes making it noexcept.
namespace std { ... error_code make_error_code(errc e) noexcept; error_condition make_error_condition(errc e) noexcept; ... }
namespace std { class error_category { public: virtual ~error_category() noexcept; ... bool operator==(const error_category& rhs) const noexcept; bool operator!=(const error_category& rhs) const noexcept; ... }; const error_category& generic_category() noexcept; const error_category& system_category() noexcept; } // namespace std
bool operator==(const error_category& rhs) const noexcept;After p. 1
bool operator!=(const error_category& rhs) const noexcept;
const error_category& generic_category() noexcept;After p. 2
const error_category& system_category() noexcept;
namespace std { class error_code { public: ... void clear() noexcept; ... }; } // namespace std
error_code make_error_code(errc e) noexcept;
void clear() noexcept;
namespace std { class error_condition { public: ... void clear() noexcept; }; } //namespace std
void clear() noexcept;
error_condition make_error_condition(errc e) noexcept;