]>
Commit | Line | Data |
---|---|---|
e4bf5dfc DS |
1 | // Specific definitions for mingw32 platform -*- C++ -*- |
2 | ||
7adcbafe | 3 | // Copyright (C) 2007-2022 Free Software Foundation, Inc. |
e4bf5dfc DS |
4 | // |
5 | // This file is part of the GNU ISO C++ Library. This library is free | |
6 | // software; you can redistribute it and/or modify it under the | |
7 | // terms of the GNU General Public License as published by the | |
748086b7 | 8 | // Free Software Foundation; either version 3, or (at your option) |
e4bf5dfc DS |
9 | // any later version. |
10 | ||
11 | // This library is distributed in the hope that it will be useful, | |
12 | // but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 | // GNU General Public License for more details. | |
15 | ||
748086b7 JJ |
16 | // Under Section 7 of GPL version 3, you are granted additional |
17 | // permissions described in the GCC Runtime Library Exception, version | |
18 | // 3.1, as published by the Free Software Foundation. | |
19 | ||
20 | // You should have received a copy of the GNU General Public License and | |
21 | // a copy of the GCC Runtime Library Exception along with this program; | |
22 | // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see | |
23 | // <http://www.gnu.org/licenses/>. | |
e4bf5dfc | 24 | |
f910786b | 25 | /** @file bits/error_constants.h |
e4bf5dfc | 26 | * This is an internal header file, included by other library headers. |
f910786b | 27 | * Do not attempt to use it directly. @headername{system_error} |
e4bf5dfc DS |
28 | */ |
29 | ||
30 | #ifndef _GLIBCXX_ERROR_CONSTANTS | |
31 | # define _GLIBCXX_ERROR_CONSTANTS | |
32 | ||
33 | #include <bits/c++config.h> | |
34 | #include <cerrno> | |
35 | ||
12ffa228 BK |
36 | namespace std _GLIBCXX_VISIBILITY(default) |
37 | { | |
38 | _GLIBCXX_BEGIN_NAMESPACE_VERSION | |
e4bf5dfc DS |
39 | |
40 | // Most of the commented-out error codes are socket-related and could be | |
4c963dce | 41 | // replaced by Winsock WSA-prefixed equivalents. |
918bf5c1 | 42 | enum class errc |
e4bf5dfc DS |
43 | { |
44 | // address_family_not_supported = EAFNOSUPPORT, | |
45 | // address_in_use = EADDRINUSE, | |
46 | // address_not_available = EADDRNOTAVAIL, | |
47 | // already_connected = EISCONN, | |
48 | argument_list_too_long = E2BIG, | |
49 | argument_out_of_domain = EDOM, | |
50 | bad_address = EFAULT, | |
51 | bad_file_descriptor = EBADF, | |
52 | // bad_message = EBADMSG, | |
53 | broken_pipe = EPIPE, | |
54 | // connection_aborted = ECONNABORTED, | |
55 | // connection_already_in_progress = EALREADY, | |
56 | // connection_refused = ECONNREFUSED, | |
57 | // connection_reset = ECONNRESET, | |
58 | // cross_device_link = EXDEV, | |
59 | // destination_address_required = EDESTADDRREQ, | |
60 | device_or_resource_busy = EBUSY, | |
61 | directory_not_empty = ENOTEMPTY, | |
62 | executable_format_error = ENOEXEC, | |
63 | file_exists = EEXIST, | |
64 | file_too_large = EFBIG, | |
65 | filename_too_long = ENAMETOOLONG, | |
66 | function_not_supported = ENOSYS, | |
67 | // host_unreachable = EHOSTUNREACH, | |
68 | // identifier_removed = EIDRM, | |
69 | illegal_byte_sequence = EILSEQ, | |
70 | inappropriate_io_control_operation = ENOTTY, | |
71 | interrupted = EINTR, | |
72 | invalid_argument = EINVAL, | |
73 | invalid_seek = ESPIPE, | |
74 | io_error = EIO, | |
75 | is_a_directory = EISDIR, | |
76 | // message_size = EMSGSIZE, | |
77 | // network_down = ENETDOWN, | |
78 | // network_reset = ENETRESET, | |
79 | // network_unreachable = ENETUNREACH, | |
80 | // no_buffer_space = ENOBUFS, | |
217d5bea | 81 | #ifdef ECHILD |
edf2239b KT |
82 | no_child_process = ECHILD, |
83 | #endif | |
e4bf5dfc DS |
84 | // no_link = ENOLINK, |
85 | no_lock_available = ENOLCK, | |
f910786b BK |
86 | // no_message_available = ENODATA, |
87 | // no_message = ENOMSG, | |
e4bf5dfc | 88 | // no_protocol_option = ENOPROTOOPT, |
217d5bea | 89 | #ifdef ENOSPC |
edf2239b KT |
90 | no_space_on_device = ENOSPC, |
91 | #endif | |
e4bf5dfc DS |
92 | // no_stream_resources = ENOSR, |
93 | no_such_device_or_address = ENXIO, | |
94 | no_such_device = ENODEV, | |
95 | no_such_file_or_directory = ENOENT, | |
96 | no_such_process = ESRCH, | |
97 | not_a_directory = ENOTDIR, | |
98 | // not_a_socket = ENOTSOCK, | |
99 | // not_a_stream = ENOSTR, | |
100 | // not_connected = ENOTCONN, | |
101 | not_enough_memory = ENOMEM, | |
217d5bea | 102 | #ifdef ENOTSUP |
edf2239b KT |
103 | not_supported = ENOTSUP, |
104 | #endif | |
e4bf5dfc DS |
105 | // operation_canceled = ECANCELED, |
106 | // operation_in_progress = EINPROGRESS, | |
217d5bea | 107 | #ifdef EPERM |
edf2239b KT |
108 | operation_not_permitted = EPERM, |
109 | #endif | |
e4bf5dfc | 110 | // operation_not_supported = EOPNOTSUPP, |
217d5bea | 111 | #ifdef EWOULDBLOCK |
edf2239b KT |
112 | operation_would_block = EWOULDBLOCK, |
113 | #endif | |
e4bf5dfc DS |
114 | // owner_dead = EOWNERDEAD, |
115 | permission_denied = EACCES, | |
116 | // protocol_error = EPROTO, | |
117 | // protocol_not_supported = EPROTONOSUPPORT, | |
118 | read_only_file_system = EROFS, | |
119 | resource_deadlock_would_occur = EDEADLK, | |
120 | resource_unavailable_try_again = EAGAIN, | |
121 | result_out_of_range = ERANGE, | |
122 | // state_not_recoverable = ENOTRECOVERABLE, | |
123 | // stream_timeout = ETIME, | |
124 | // text_file_busy = ETXTBSY, | |
217d5bea | 125 | #ifdef ETIMEDOUT |
edf2239b KT |
126 | timed_out = ETIMEDOUT, |
127 | #endif | |
e4bf5dfc DS |
128 | too_many_files_open_in_system = ENFILE, |
129 | too_many_files_open = EMFILE, | |
918bf5c1 | 130 | too_many_links = EMLINK |
54e776dc | 131 | // too_many_symbolic_link_levels = ELOOP, |
217d5bea | 132 | #ifdef EOVERFLOW |
54e776dc PC |
133 | , |
134 | value_too_large = EOVERFLOW | |
edf2239b | 135 | #endif |
54e776dc | 136 | // wrong_protocol_type = EPROTOTYPE |
e4bf5dfc DS |
137 | }; |
138 | ||
12ffa228 BK |
139 | _GLIBCXX_END_NAMESPACE_VERSION |
140 | } // namespace | |
e4bf5dfc DS |
141 | |
142 | #endif |