libstdc++
|
00001 // Specific definitions for generic platforms -*- C++ -*- 00002 00003 // Copyright (C) 2007, 2008, 2009, 2010 Free Software Foundation, Inc. 00004 // 00005 // This file is part of the GNU ISO C++ Library. This library is free 00006 // software; you can redistribute it and/or modify it under the 00007 // terms of the GNU General Public License as published by the 00008 // Free Software Foundation; either version 3, or (at your option) 00009 // any later version. 00010 00011 // This library is distributed in the hope that it will be useful, 00012 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 // GNU General Public License for more details. 00015 00016 // Under Section 7 of GPL version 3, you are granted additional 00017 // permissions described in the GCC Runtime Library Exception, version 00018 // 3.1, as published by the Free Software Foundation. 00019 00020 // You should have received a copy of the GNU General Public License and 00021 // a copy of the GCC Runtime Library Exception along with this program; 00022 // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see 00023 // <http://www.gnu.org/licenses/>. 00024 00025 /** @file bits/error_constants.h 00026 * This is an internal header file, included by other library headers. 00027 * Do not attempt to use it directly. @headername{system_error} 00028 */ 00029 00030 #ifndef _GLIBCXX_ERROR_CONSTANTS 00031 #define _GLIBCXX_ERROR_CONSTANTS 1 00032 00033 #include <bits/c++config.h> 00034 #include <cerrno> 00035 00036 namespace std _GLIBCXX_VISIBILITY(default) 00037 { 00038 _GLIBCXX_BEGIN_NAMESPACE_VERSION 00039 00040 enum class errc 00041 { 00042 address_family_not_supported = EAFNOSUPPORT, 00043 address_in_use = EADDRINUSE, 00044 address_not_available = EADDRNOTAVAIL, 00045 already_connected = EISCONN, 00046 argument_list_too_long = E2BIG, 00047 argument_out_of_domain = EDOM, 00048 bad_address = EFAULT, 00049 bad_file_descriptor = EBADF, 00050 00051 #ifdef _GLIBCXX_HAVE_EBADMSG 00052 bad_message = EBADMSG, 00053 #endif 00054 00055 broken_pipe = EPIPE, 00056 connection_aborted = ECONNABORTED, 00057 connection_already_in_progress = EALREADY, 00058 connection_refused = ECONNREFUSED, 00059 connection_reset = ECONNRESET, 00060 cross_device_link = EXDEV, 00061 destination_address_required = EDESTADDRREQ, 00062 device_or_resource_busy = EBUSY, 00063 directory_not_empty = ENOTEMPTY, 00064 executable_format_error = ENOEXEC, 00065 file_exists = EEXIST, 00066 file_too_large = EFBIG, 00067 filename_too_long = ENAMETOOLONG, 00068 function_not_supported = ENOSYS, 00069 host_unreachable = EHOSTUNREACH, 00070 00071 #ifdef _GLIBCXX_HAVE_EIDRM 00072 identifier_removed = EIDRM, 00073 #endif 00074 00075 illegal_byte_sequence = EILSEQ, 00076 inappropriate_io_control_operation = ENOTTY, 00077 interrupted = EINTR, 00078 invalid_argument = EINVAL, 00079 invalid_seek = ESPIPE, 00080 io_error = EIO, 00081 is_a_directory = EISDIR, 00082 message_size = EMSGSIZE, 00083 network_down = ENETDOWN, 00084 network_reset = ENETRESET, 00085 network_unreachable = ENETUNREACH, 00086 no_buffer_space = ENOBUFS, 00087 no_child_process = ECHILD, 00088 00089 #ifdef _GLIBCXX_HAVE_ENOLINK 00090 no_link = ENOLINK, 00091 #endif 00092 00093 no_lock_available = ENOLCK, 00094 00095 #ifdef _GLIBCXX_HAVE_ENODATA 00096 no_message_available = ENODATA, 00097 #endif 00098 00099 no_message = ENOMSG, 00100 no_protocol_option = ENOPROTOOPT, 00101 no_space_on_device = ENOSPC, 00102 00103 #ifdef _GLIBCXX_HAVE_ENOSR 00104 no_stream_resources = ENOSR, 00105 #endif 00106 00107 no_such_device_or_address = ENXIO, 00108 no_such_device = ENODEV, 00109 no_such_file_or_directory = ENOENT, 00110 no_such_process = ESRCH, 00111 not_a_directory = ENOTDIR, 00112 not_a_socket = ENOTSOCK, 00113 00114 #ifdef _GLIBCXX_HAVE_ENOSTR 00115 not_a_stream = ENOSTR, 00116 #endif 00117 00118 not_connected = ENOTCONN, 00119 not_enough_memory = ENOMEM, 00120 00121 #ifdef _GLIBCXX_HAVE_ENOTSUP 00122 not_supported = ENOTSUP, 00123 #endif 00124 00125 #ifdef _GLIBCXX_HAVE_ECANCELED 00126 operation_canceled = ECANCELED, 00127 #endif 00128 00129 operation_in_progress = EINPROGRESS, 00130 operation_not_permitted = EPERM, 00131 operation_not_supported = EOPNOTSUPP, 00132 operation_would_block = EWOULDBLOCK, 00133 00134 #ifdef _GLIBCXX_HAVE_EOWNERDEAD 00135 owner_dead = EOWNERDEAD, 00136 #endif 00137 00138 permission_denied = EACCES, 00139 00140 #ifdef _GLIBCXX_HAVE_EPROTO 00141 protocol_error = EPROTO, 00142 #endif 00143 00144 protocol_not_supported = EPROTONOSUPPORT, 00145 read_only_file_system = EROFS, 00146 resource_deadlock_would_occur = EDEADLK, 00147 resource_unavailable_try_again = EAGAIN, 00148 result_out_of_range = ERANGE, 00149 00150 #ifdef _GLIBCXX_HAVE_ENOTRECOVERABLE 00151 state_not_recoverable = ENOTRECOVERABLE, 00152 #endif 00153 00154 #ifdef _GLIBCXX_HAVE_ETIME 00155 stream_timeout = ETIME, 00156 #endif 00157 00158 #ifdef _GLIBCXX_HAVE_ETXTBSY 00159 text_file_busy = ETXTBSY, 00160 #endif 00161 00162 timed_out = ETIMEDOUT, 00163 too_many_files_open_in_system = ENFILE, 00164 too_many_files_open = EMFILE, 00165 too_many_links = EMLINK, 00166 too_many_symbolic_link_levels = ELOOP, 00167 00168 #ifdef _GLIBCXX_HAVE_EOVERFLOW 00169 value_too_large = EOVERFLOW, 00170 #endif 00171 00172 wrong_protocol_type = EPROTOTYPE 00173 }; 00174 00175 _GLIBCXX_END_NAMESPACE_VERSION 00176 } // namespace 00177 00178 #endif