pub unsafe trait Field:
Send
+ Sync
+ Copy {
type Base;
type Type;
const OFFSET: usize = _;
}🔬This is a nightly-only experimental API. (
field_projections #145383)Expand description
Type representing a field of a struct, union, enum variant or tuple.
§Safety
Given a valid value of type Self::Base, there exists a valid value of type Self::Type at
byte offset OFFSET
Provided Associated Constants§
Required Associated Types§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".