pub trait BitFieldTrait: Sealed {
type Owner;
const SHIFT: u32;
const MASK: u64;
}Expand description
Tracks the Owner, shift and mask used by the Storage::* methods to provide access
to an owned bit field.
Note: this trait is sealed against implementation outside this crate. This restriction will be lifted once the API has stabilized.
Required Associated Constants§
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.
Implementors§
Source§impl<TOwner, TShift, TMask> BitFieldTrait for BitFieldImpl<TOwner, TShift, TMask>
Implementation for BitFieldImpl explicitly converts the typenum shift and mask calculations
into constants. Forcing the conversion here prevents infinite recursion by the compiler when
these values are used by Storage to provide access to the field.
impl<TOwner, TShift, TMask> BitFieldTrait for BitFieldImpl<TOwner, TShift, TMask>
Implementation for BitFieldImpl explicitly converts the typenum shift and mask calculations
into constants. Forcing the conversion here prevents infinite recursion by the compiler when
these values are used by Storage to provide access to the field.