Trait Const

Source
pub trait Const<T> {
    const VALUE: T;
}
Expand description

A trait whose types-implementors represent a constant value of type T.

Required Associated Constants§

Source

const VALUE: T

The constant value of type T.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<const VAL: bool> Const<bool> for ConstTypeBool<VAL>

Source§

const VALUE: bool = VAL