Proposed resolution:
Change System error support [syserr] as indicated:
namespace posix_error {enumposix_errnoclass errc { address_family_not_supported, // EAFNOSUPPORT ... wrong_protocol_type, // EPROTOTYPE };} // namespace posix_errortemplate <> struct is_error_condition_enum<posix_error::posix_errnoerrc> : public true_type {}namespace posix_error {error_code make_error_code(posix_errnoerrc e); error_condition make_error_condition(posix_errnoerrc e);} // namespace posix_error
Change System error support [syserr] :
The is_error_code_enum and is_error_condition_enum templates may be specialized for user-defined types to indicate that such a type is eligible for class error_code and class error_condition automatic conversions, respectively.
Change System error support [syserr] and its subsections:
- remove all occurrences of posix_error::
- change all instances of posix_errno to errc
- change all instances of posix_category to generic_category
- change all instances of get_posix_category to get_generic_category
Change Error category objects [syserr.errcat.objects], paragraph 2:
Remarks: The object's default_error_condition and equivalent virtual functions shall behave as specified for the class error_category. The object's name virtual function shall return a pointer to the string
"POSIX""generic".
Change [syserr.errcode.nonmembers] Class error_code non-member functions as indicated:
error_code make_error_code(posix_errnoerrc e);Returns: error_code(static_cast<int>(e),
posixgeneric_category).
Change [syserr.errcondition.nonmembers] Class error_condition non-member functions as indicated:
error_condition make_error_condition(posix_errnoerrc e);Returns: error_condition(static_cast<int>(e),
posixgeneric_category).