nxt.expected

Wrapper type for a sum-type (union) of an unexpected and expected value.

Members

Functions

expected
auto expected(T expectedValue)

Insantiator for Expected from an expected value expectedValue.

unexpected
auto unexpected(E unexpectedValue)

Insantiator for Expected from an unexpected value unexpectedValue.

Structs

Expected
struct Expected(T, E = Exception)

Union (sum) type of either an expected (most probable) value of type T or an unexpected value of type E (being an instance of type Unexpected!E).

Meta