swc_core::ecma::utils

Trait StmtLike

pub trait StmtLike:
    Sized
    + 'static
    + Send
    + Sync
    + From<Stmt> {
    // Required methods
    fn try_into_stmt(self) -> Result<Stmt, Self>;
    fn as_stmt(&self) -> Option<&Stmt>;
    fn as_stmt_mut(&mut self) -> Option<&mut Stmt>;
}
Available on crate features __ecma and __utils only.

Required Methods§

fn try_into_stmt(self) -> Result<Stmt, Self>

fn as_stmt(&self) -> Option<&Stmt>

fn as_stmt_mut(&mut self) -> Option<&mut Stmt>

Object Safety§

This trait is not object safe.

Implementors§