#[non_exhaustive]pub struct ItemImpl {
pub attributes: Vec<Attribute>,
pub impl_: Impl,
pub path: Path,
pub open: OpenBrace,
pub items: Vec<(ImplItem, Option<SemiColon>)>,
pub close: CloseBrace,
}Expand description
An impl item.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.attributes: Vec<Attribute>The attributes of the impl block
impl_: ImplThe impl keyword.
path: PathPath of the implementation.
open: OpenBraceThe open brace.
items: Vec<(ImplItem, Option<SemiColon>)>The functions and constants of the impl, in the order they were written, each with the semicolon which followed it if any. A constant is always followed by one.
close: CloseBraceThe close brace.
Trait Implementations§
impl Eq for ItemImpl
Source§impl OptionSpanned for ItemImpl
impl OptionSpanned for ItemImpl
Source§fn option_span(&self) -> Option<Span>
fn option_span(&self) -> Option<Span>
Get the optional span of the type.
impl StructuralPartialEq for ItemImpl
Auto Trait Implementations§
impl Forget for ItemImpl
impl Freeze for ItemImplwhere
*const Attribute is !null: Freeze,
PhantomData<Attribute>: Freeze,
*const (PathSegmentExpr, Option<Comma>) is !null: Freeze,
PhantomData<(PathSegmentExpr, Option<Comma>)>: Freeze,
*const (ColonColon, PathSegment) is !null: Freeze,
PhantomData<(ColonColon, PathSegment)>: Freeze,
*const (ImplItem, Option<SemiColon>) is !null: Freeze,
PhantomData<(ImplItem, Option<SemiColon>)>: Freeze,
impl Move for ItemImpl
impl RefUnwindSafe for ItemImpl
impl Send for ItemImplwhere
Unique<Attribute>: Send,
Unique<(PathSegmentExpr, Option<Comma>)>: Send,
Unique<(ColonColon, PathSegment)>: Send,
Unique<(ImplItem, Option<SemiColon>)>: Send,
impl Sync for ItemImplwhere
Unique<Attribute>: Sync,
Unique<(PathSegmentExpr, Option<Comma>)>: Sync,
Unique<(ColonColon, PathSegment)>: Sync,
Unique<(ImplItem, Option<SemiColon>)>: Sync,
impl Unpin for ItemImplwhere
*const Attribute is !null: Unpin,
*const (PathSegmentExpr, Option<Comma>) is !null: Unpin,
Box<Expr>: Unpin,
Box<Condition>: Unpin,
Box<Block>: Unpin,
*const (Pat, Option<Comma>) is !null: Unpin,
Box<Pat>: Unpin,
*const ExprElseIf is !null: Unpin,
*const (ExprMatchBranch, Option<Comma>) is !null: Unpin,
*const (Expr, Option<Comma>) is !null: Unpin,
*const Stmt is !null: Unpin,
Box<Local>: Unpin,
*const (ItemUsePath, Option<Comma>) is !null: Unpin,
*const (ColonColon, ItemUseSegment) is !null: Unpin,
*const (FnArg, Option<Comma>) is !null: Unpin,
*const (Box<Type>, Option<Comma>) is !null: Unpin,
Box<Type>: Unpin,
*const (ItemVariant, Option<Comma>) is !null: Unpin,
*const (Field, Option<Comma>) is !null: Unpin,
Box<File>: Unpin,
NonZero<u32>: Unpin,
*const Token is !null: Unpin,
*const (ExprSelectBranch, Option<Comma>) is !null: Unpin,
*const (FieldAssign, Option<Comma>) is !null: Unpin,
*const (ColonColon, PathSegment) is !null: Unpin,
*const (ImplItem, Option<SemiColon>) is !null: Unpin,
impl UnsafeUnpin for ItemImplwhere
*const Attribute is !null: UnsafeUnpin,
PhantomData<Attribute>: UnsafeUnpin,
*const (PathSegmentExpr, Option<Comma>) is !null: UnsafeUnpin,
PhantomData<(PathSegmentExpr, Option<Comma>)>: UnsafeUnpin,
*const (ColonColon, PathSegment) is !null: UnsafeUnpin,
PhantomData<(ColonColon, PathSegment)>: UnsafeUnpin,
*const (ImplItem, Option<SemiColon>) is !null: UnsafeUnpin,
PhantomData<(ImplItem, Option<SemiColon>)>: UnsafeUnpin,
impl UnwindSafe for ItemImplwhere
NonNull<Attribute>: UnwindSafe,
NonNull<(PathSegmentExpr, Option<Comma>)>: UnwindSafe,
NonNull<Expr>: UnwindSafe,
NonNull<Condition>: UnwindSafe,
NonNull<(Pat, Option<Comma>)>: UnwindSafe,
NonNull<Pat>: UnwindSafe,
NonNull<Block>: UnwindSafe,
NonNull<Stmt>: UnwindSafe,
NonNull<Local>: UnwindSafe,
NonNull<(ItemUsePath, Option<Comma>)>: UnwindSafe,
NonNull<(ColonColon, ItemUseSegment)>: UnwindSafe,
NonNull<(FnArg, Option<Comma>)>: UnwindSafe,
NonNull<(Box<Type>, Option<Comma>)>: UnwindSafe,
NonNull<Type>: UnwindSafe,
NonNull<(ItemVariant, Option<Comma>)>: UnwindSafe,
NonNull<(Field, Option<Comma>)>: UnwindSafe,
NonNull<File>: UnwindSafe,
NonNull<(Item, Option<SemiColon>)>: UnwindSafe,
NonZero<u32>: UnwindSafe,
NonNull<Token>: UnwindSafe,
NonNull<ExprElseIf>: UnwindSafe,
NonNull<(ExprMatchBranch, Option<Comma>)>: UnwindSafe,
NonNull<(Expr, Option<Comma>)>: UnwindSafe,
NonNull<(ExprSelectBranch, Option<Comma>)>: UnwindSafe,
NonNull<(FieldAssign, Option<Comma>)>: UnwindSafe,
NonNull<(ColonColon, PathSegment)>: UnwindSafe,
NonNull<(ImplItem, Option<SemiColon>)>: UnwindSafe,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.