Enum
error-code
Error codes returned by functions, similar to errno in POSIX.
Not all of these error codes are returned by the functions provided by this
API; some are used in higher-level library layers, and others are provided
merely for alignment with POSIX.
enum error-code {
access,
would-block,
already,
bad-descriptor,
busy,
deadlock,
quota,
exist,
file-too-large,
illegal-byte-sequence,
in-progress,
interrupted,
invalid,
io,
is-directory,
loop,
too-many-links,
message-size,
name-too-long,
no-device,
no-entry,
no-lock,
insufficient-memory,
insufficient-space,
not-directory,
not-empty,
not-recoverable,
unsupported,
no-tty,
no-such-device,
overflow,
not-permitted,
pipe,
read-only,
invalid-seek,
text-file-busy,
cross-device,
}Cases
| Case | Description |
|---|---|
| access | Permission denied, similar to EACCES in POSIX. |
| would-block | Resource unavailable, or operation would block, similar to EAGAIN and EWOULDBLOCK in POSIX. |
| already | Connection already in progress, similar to EALREADY in POSIX. |
| bad-descriptor | Bad descriptor, similar to EBADF in POSIX. |
| busy | Device or resource busy, similar to EBUSY in POSIX. |
| deadlock | Resource deadlock would occur, similar to EDEADLK in POSIX. |
| quota | Storage quota exceeded, similar to EDQUOT in POSIX. |
| exist | File exists, similar to EEXIST in POSIX. |
| file-too-large | File too large, similar to EFBIG in POSIX. |
| illegal-byte-sequence | Illegal byte sequence, similar to EILSEQ in POSIX. |
| in-progress | Operation in progress, similar to EINPROGRESS in POSIX. |
| interrupted | Interrupted function, similar to EINTR in POSIX. |
| invalid | Invalid argument, similar to EINVAL in POSIX. |
| io | I/O error, similar to EIO in POSIX. |
| is-directory | Is a directory, similar to EISDIR in POSIX. |
| loop | Too many levels of symbolic links, similar to ELOOP in POSIX. |
| too-many-links | Too many links, similar to EMLINK in POSIX. |
| message-size | Message too large, similar to EMSGSIZE in POSIX. |
| name-too-long | Filename too long, similar to ENAMETOOLONG in POSIX. |
| no-device | No such device, similar to ENODEV in POSIX. |
| no-entry | No such file or directory, similar to ENOENT in POSIX. |
| no-lock | No locks available, similar to ENOLCK in POSIX. |
| insufficient-memory | Not enough space, similar to ENOMEM in POSIX. |
| insufficient-space | No space left on device, similar to ENOSPC in POSIX. |
| not-directory | Not a directory or a symbolic link to a directory, similar to ENOTDIR in POSIX. |
| not-empty | Directory not empty, similar to ENOTEMPTY in POSIX. |
| not-recoverable | State not recoverable, similar to ENOTRECOVERABLE in POSIX. |
| unsupported | Not supported, similar to ENOTSUP and ENOSYS in POSIX. |
| no-tty | Inappropriate I/O control operation, similar to ENOTTY in POSIX. |
| no-such-device | No such device or address, similar to ENXIO in POSIX. |
| overflow | Value too large to be stored in data type, similar to EOVERFLOW in POSIX. |
| not-permitted | Operation not permitted, similar to EPERM in POSIX. |
| pipe | Broken pipe, similar to EPIPE in POSIX. |
| read-only | Read-only file system, similar to EROFS in POSIX. |
| invalid-seek | Invalid seek, similar to ESPIPE in POSIX. |
| text-file-busy | Text file busy, similar to ETXTBSY in POSIX. |
| cross-device | Cross-device link, similar to EXDEV in POSIX. |