Crate sigma_types

Source
Expand description

Types that maintain a given invariant.

Modules§

i8
Terms of type $t less than a constant (defined by PartialOrd comparison).
i16
Terms of type $t less than a constant (defined by PartialOrd comparison).
i32
Terms of type $t less than a constant (defined by PartialOrd comparison).
i64
Terms of type $t less than a constant (defined by PartialOrd comparison).
i128
Terms of type $t less than a constant (defined by PartialOrd comparison).
isize
Terms of type $t less than a constant (defined by PartialOrd comparison).
u8
Terms of type $t less than a constant (defined by PartialOrd comparison).
u16
Terms of type $t less than a constant (defined by PartialOrd comparison).
u32
Terms of type $t less than a constant (defined by PartialOrd comparison).
u64
Terms of type $t less than a constant (defined by PartialOrd comparison).
u128
Terms of type $t less than a constant (defined by PartialOrd comparison).
usize
Terms of type $t less than a constant (defined by PartialOrd comparison).

Structs§

All
Iterable data structure in which each element satisfies a given invariant.
AllPairs
Iterable data structure in which each adjacent pair of elements satisfies a given invariant.
FiniteInvariant
Finite terms (e.g. for floating points, not NaN, infinite, etc.).
NegativeInvariant
Negative terms (defined by comparison to zero).
NonNegativeInvariant
Non-negative terms (defined by comparison to zero).
NonPositiveInvariant
Non-positive terms (defined by comparison to zero).
NonZeroInvariant
Nonzero terms (defined by comparison to zero).
NotAll
At least one element in an iterator did not satisfy the given invariant.
NotAllPairs
At least one pair in an iterator did not satisfy the given invariant.
NotFinite
A term expected to be finite was not.
NotNegative
A term expected to be positive was not.
NotNonNegative
A term expected to be non-negative was, in fact, negative.
NotNonPositive
A term expected to be non-positive was, in fact, positive.
NotNonZero
A term expected to be nonzero was, in fact, zero.
NotOnUnit
Term expected to be on the unit interval (between 0 and 1) was not.
NotPositive
A term expected to be positive was not.
OnUnitInvariant
Terms on the unit interval (between 0 and 1), either inclusive or exclusive at each extreme.
PositiveInvariant
Positive terms (defined by comparison to zero).
Sigma
Type that maintains a given invariant.
SortedPair
Pair guaranteed to be sorted left-to-right (optionally permitted to be equal).

Enums§

OutOfOrder
Some elements in a supposedly sorted iterator were not sorted.

Traits§

CanBeInfinite
Types that can represent infinite values.
One
Types equipped with a multiplicative identity (i.e., one).
Test
Function-like type that checks an invariant and optionally provides an error message.
Zero
Types equipped with an additive identity (i.e., zero).

Type Aliases§

Finite
Finite terms (e.g. for floating points, not NaN, infinite, etc.).
Negative
Negative terms (defined by comparison to zero).
NonNegative
Non-negative terms (defined by comparison to zero).
NonPositive
Non-positive terms (defined by comparison to zero).
NonZero
Nonzero terms (defined by comparison to zero).
OnUnit
Terms on the unit interval (between 0 and 1), either inclusive or exclusive at each extreme.
Positive
Positive terms (defined by comparison to zero).
Sorted
Iterable data structure guaranteed to be sorted (optionally with or without duplicates).
SortedInvariant
Iterable data structure guaranteed to be sorted (optionally with or without duplicates).