Crate integral_constant

Source
Expand description

This crate provides type-level representations of constant values. The name integral_constant is a reference to std::integral_constant in C++, which serves a similar purpose. Unlike std::integral_constant, this crate provides separate wrapper types depending on the type of the constant value, since the type of const generics in Rust cannot depend on type parameters.

Structs§

Bool
A bool represented as a type.
Char
A char represented as a type.
I8
An i8 represented as a type.
I16
An i16 represented as a type.
I32
An i32 represented as a type.
I64
An i64 represented as a type.
I128
An i128 represented as a type.
Isize
An isize represented as a type.
U8
A u8 represented as a type.
U16
A u16 represented as a type.
U32
A u32 represented as a type.
U64
A u64 represented as a type.
U128
A u128 represented as a type.
Usize
A usize represented as a type.

Traits§

Constant
A type-level constant.