pub trait SizeEq<Src: ?Sized> {
type CastFrom: CastExact<Src, Self>;
}Expand description
Carries the ability to perform a size-preserving cast or conversion from a
raw pointer to Src to a raw pointer to Self.
The cast/conversion is carried by the associated CastFrom type, and
may be a no-op cast (without updating pointer metadata) or a conversion
which updates pointer metadata.
§Safety
SizeEq on its own conveys no safety guarantee. Any safety guarantees come
from the safety invariants on the associated CastFrom type, specifically
the CastExact bound.
Required Associated Types§
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.