pub trait IsType {
// Provided method
fn is<T>(&self) -> bool
where T: 'static,
Self: 'static { ... }
}Expand description
The IsType trait provides a method to check if the current type is of a specific type
at runtime. This is useful for dynamic type checking in scenarios where the type may not be
known at compile time.
Provided Methods§
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.