pub struct TryStmt {
pub block: Vec<Statement>,
pub catch_param: Option<Box<Pattern>>,
pub catch_block: Option<Vec<Statement>>,
pub finally_block: Option<Vec<Statement>>,
}Expand description
switch の 1 ケース。test が None なら default。
try 文の中身(Statement::Try が箱に入れて持つ)。
Fields§
§block: Vec<Statement>§catch_param: Option<Box<Pattern>>catch (e)/catch ({message}) 等。分割代入パターンにも対応(ES2015)。
catch_block: Option<Vec<Statement>>§finally_block: Option<Vec<Statement>>Trait Implementations§
impl StructuralPartialEq for TryStmt
Auto Trait Implementations§
impl !RefUnwindSafe for TryStmt
impl !Send for TryStmt
impl !Sync for TryStmt
impl !UnwindSafe for TryStmt
impl Freeze for TryStmt
impl Unpin for TryStmt
impl UnsafeUnpin for TryStmt
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