pub struct TypeAnnotation {
pub target_type: u8,
pub target: TypeAnnotationTarget,
pub path: Vec<TypePathEntry>,
pub type_index: u16,
pub elements: Vec<AnnotationElement>,
pub origin: AttributeOrigin,
}Expand description
One type annotation, including its target union and component path.
Fields§
§target_type: u8Exact target-type discriminator.
target: TypeAnnotationTargetTarget data selected by target_type.
path: Vec<TypePathEntry>Component path in encoded order.
type_index: u16Annotation type index.
elements: Vec<AnnotationElement>Ordered annotation element pairs.
origin: AttributeOriginSource range of the complete type annotation.
Trait Implementations§
Source§impl Clone for TypeAnnotation
impl Clone for TypeAnnotation
Source§fn clone(&self) -> TypeAnnotation
fn clone(&self) -> TypeAnnotation
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TypeAnnotation
impl Debug for TypeAnnotation
impl Eq for TypeAnnotation
Source§impl PartialEq for TypeAnnotation
impl PartialEq for TypeAnnotation
impl StructuralPartialEq for TypeAnnotation
Auto Trait Implementations§
impl Freeze for TypeAnnotation
impl RefUnwindSafe for TypeAnnotation
impl Send for TypeAnnotation
impl Sync for TypeAnnotation
impl Unpin for TypeAnnotation
impl UnsafeUnpin for TypeAnnotation
impl UnwindSafe for TypeAnnotation
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more