tmp/tmpiiw1uwdf/{from.md → to.md}
RENAMED
|
@@ -1,19 +1,19 @@
|
|
| 1 |
#### Value of error codes <a id="value.error.codes">[[value.error.codes]]</a>
|
| 2 |
|
| 3 |
Certain functions in the C++ standard library report errors via a
|
| 4 |
-
`std::error_code`
|
| 5 |
`category()` member shall return `std::system_category()` for errors
|
| 6 |
originating from the operating system, or a reference to an
|
| 7 |
*implementation-defined* `error_category` object for errors originating
|
| 8 |
elsewhere. The implementation shall define the possible values of
|
| 9 |
`value()` for each of these error categories.
|
| 10 |
|
| 11 |
[*Example 1*: For operating systems that are based on POSIX,
|
| 12 |
-
implementations
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
|
|
|
|
| 1 |
#### Value of error codes <a id="value.error.codes">[[value.error.codes]]</a>
|
| 2 |
|
| 3 |
Certain functions in the C++ standard library report errors via a
|
| 4 |
+
`std::error_code` [[syserr.errcode.overview]] object. That object’s
|
| 5 |
`category()` member shall return `std::system_category()` for errors
|
| 6 |
originating from the operating system, or a reference to an
|
| 7 |
*implementation-defined* `error_category` object for errors originating
|
| 8 |
elsewhere. The implementation shall define the possible values of
|
| 9 |
`value()` for each of these error categories.
|
| 10 |
|
| 11 |
[*Example 1*: For operating systems that are based on POSIX,
|
| 12 |
+
implementations should define the `std::system_category()` values as
|
| 13 |
+
identical to the POSIX `errno` values, with additional values as defined
|
| 14 |
+
by the operating system’s documentation. Implementations for operating
|
| 15 |
+
systems that are not based on POSIX should define values identical to
|
| 16 |
+
the operating system’s values. For errors that do not originate from the
|
| 17 |
+
operating system, the implementation may provide enums for the
|
| 18 |
+
associated values. — *end example*]
|
| 19 |
|