Expand description
Types,traits,and functions used by prefix-types.
Structs§
- PTStruct
Layout - Represents the layout of a prefix-type,for use in error messages.
- Prefix
Ref - A reference to a prefix type.
- With
Metadata_ - Wraps a type along with its prefix-type-related metadata, so that it can be converted to its prefix.
Enums§
- IsAccessible
- Whether a field is accessible.
- IsConditional
- Whether a field is conditional,
whether it has a
#[sabi(accessible_if = expression)]
helper attribute or not.
Traits§
- Prefix
RefTrait - Marker trait for pointers to prefix field structs.
- Prefix
Type Trait - For types deriving
StableAbi
with#[sabi(kind(Prefix(..)))]
.
Functions§
- panic_
on_ missing_ field_ ty - Used to panic with an error message informing the user that a field
is expected to be on the
T
type when it’s not. - panic_
on_ missing_ fieldname - Used to panic with an error message informing the user that a field
is expected to be on the
T
type when it’s not.
Type Aliases§
- Field
Accessibility - An array with whether the ith field of a prefix-type is accessible through its accessor method.
- Field
Conditionality - An array with whether the ith field in the prefix of a prefix-type
is conditional,which means whether it has the
#[sabi(accessible_if = expression)]
attribute applied to it. - With
Metadata - Alias for
WithMetadata_
that defaults to passing<T as PrefixTypeTrait>::PrefixFields
as the second type parameter.