pub struct CatchClause {
pub param: Option<Pattern>,
pub body: Vec<Stmt>,
pub span: Span,
}Expand description
The catch half of a try statement.
Fields§
§param: Option<Pattern>Bound error, if any (catch { } has none).
body: Vec<Stmt>Handler body.
span: SpanSource range.
Trait Implementations§
Source§impl Clone for CatchClause
impl Clone for CatchClause
Source§impl Debug for CatchClause
impl Debug for CatchClause
Source§impl PartialEq for CatchClause
impl PartialEq for CatchClause
impl StructuralPartialEq for CatchClause
Auto Trait Implementations§
impl Forget for CatchClause
impl Freeze for CatchClausewhere
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<Option<PatternElement>>: Freeze,
*const RestElement is !null: Freeze,
PhantomData<RestElement>: Freeze,
*const Pattern is !null: Freeze,
PhantomData<Pattern>: Freeze,
*const Expr is !null: Freeze,
PhantomData<Expr>: Freeze,
*const MemberPattern is !null: Freeze,
PhantomData<MemberPattern>: Freeze,
PhantomData<Stmt>: Freeze,
impl Move for CatchClause
impl RefUnwindSafe for CatchClause
impl Send for CatchClausewhere
RawVecInner: Send,
BoxRaw<Expr>: Send,
BoxRaw<RestElement>: Send,
BoxRaw<Pattern>: Send,
BoxRaw<MemberPattern>: Send,
BoxRaw<Stmt>: Send,
BoxRaw<Function>: Send,
BoxRaw<Class>: Send,
BoxRaw<ImportDecl>: Send,
BoxRaw<ExportDecl>: Send,
impl Sync for CatchClausewhere
RawVecInner: Sync,
BoxRaw<Expr>: Sync,
BoxRaw<RestElement>: Sync,
BoxRaw<Pattern>: Sync,
BoxRaw<MemberPattern>: Sync,
BoxRaw<Stmt>: Sync,
BoxRaw<Function>: Sync,
BoxRaw<Class>: Sync,
BoxRaw<ImportDecl>: Sync,
BoxRaw<ExportDecl>: Sync,
impl Unpin for CatchClause
impl UnsafeUnpin for CatchClausewhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<Option<PatternElement>>: UnsafeUnpin,
*const RestElement is !null: UnsafeUnpin,
PhantomData<RestElement>: UnsafeUnpin,
*const Pattern is !null: UnsafeUnpin,
PhantomData<Pattern>: UnsafeUnpin,
*const Expr is !null: UnsafeUnpin,
PhantomData<Expr>: UnsafeUnpin,
*const MemberPattern is !null: UnsafeUnpin,
PhantomData<MemberPattern>: UnsafeUnpin,
PhantomData<Stmt>: UnsafeUnpin,
impl UnwindSafe for CatchClausewhere
RawVecInner: UnwindSafe,
BoxRaw<Expr>: UnwindSafe,
BoxRaw<RestElement>: UnwindSafe,
BoxRaw<Pattern>: UnwindSafe,
BoxRaw<MemberPattern>: UnwindSafe,
BoxRaw<Stmt>: UnwindSafe,
BoxRaw<Function>: UnwindSafe,
BoxRaw<Class>: UnwindSafe,
BoxRaw<ImportDecl>: UnwindSafe,
BoxRaw<ExportDecl>: 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