API reference Dodo 0.1.4

std/platform/error

Public declarations, types, methods, and source contracts for std/platform/error.

On this page

Library guide · API index and notation

This page is generated from the bundled library in this checkout. Signatures and adjacent source comments are reproduced below; the linked guide explains usage, storage, failures, and platform support.

import "std/platform/error"

Names used in signatures

Unqualified names denote this package’s types (including other source files in the same package), language built-ins, or generic parameters such as T. Qualified names use the import aliases below. These aliases belong to the library source; import a dependency yourself to use its alias in your program.

Alias Package Source file
io std/io error.dodo

Kind

Enum · Source

The domain is the selected hosted adapter: errno on Linux, GetLastError on Windows. Library-generated errors use code zero; native codes are retained.

pub enum Kind {
    InvalidInput, Unsupported, NotFound, AlreadyExists, PermissionDenied,
    Interrupted, WouldBlock, TimedOut, Cancelled, BufferTooSmall, CrossDevice,
    NotDirectory, IsDirectory, DirectoryNotEmpty, Closed, Other, BrokenPipe
}

Error

Struct · Source

pub struct Error {
    pub kind: Kind
    pub code: i32
}

Error.format

Function · Source

Only fixed kind names and numeric metadata; never input or native messages.

pub fn format<F>(&self, output: &mut F) -> void!io.Error

failure

Function · Source

pub fn failure(kind: Kind) -> Error

Type to search all documentation.

Keyboard shortcuts

Search documentation
Ctrl K or /
Move through results
↑ ↓
Open selected result
Enter
Close a dialog
Esc
Show these shortcuts
?