pub trait Constraint<T> {
const NAME: &'static str;
// Required method
fn satisfied(value: &T) -> bool;
}Expand description
A constraint that a Safe<T, C> value must satisfy.
Implement this for a zero-sized marker type C to make it usable with
Safe::try_new and the crate::safe! macro.
Required Associated Constants§
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".