Trait swc_ecma_visit::VisitWith
source · pub trait VisitWith<V: ?Sized + Visit> {
// Required methods
fn visit_with(&self, v: &mut V);
fn visit_children_with(&self, v: &mut V);
}
Expand description
A utility trait implemented for ast nodes, and allow to visit them with a visitor.
Required Methods§
sourcefn visit_with(&self, v: &mut V)
fn visit_with(&self, v: &mut V)
Calls a visitor method (v.visit_xxx) with self.
sourcefn visit_children_with(&self, v: &mut V)
fn visit_children_with(&self, v: &mut V)
Visit children nodes of self with v
Implementations on Foreign Types§
source§impl<V: ?Sized + Visit> VisitWith<V> for TsModuleRef
impl<V: ?Sized + Visit> VisitWith<V> for TsModuleRef
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsSetterSignature
impl<V: ?Sized + Visit> VisitWith<V> for TsSetterSignature
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for BinaryOp
impl<V: ?Sized + Visit> VisitWith<V> for BinaryOp
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ExportAll
impl<V: ?Sized + Visit> VisitWith<V> for ExportAll
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Atom
impl<V: ?Sized + Visit> VisitWith<V> for Atom
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ThisExpr
impl<V: ?Sized + Visit> VisitWith<V> for ThisExpr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for [ExprOrSpread]
impl<V: ?Sized + Visit> VisitWith<V> for [ExprOrSpread]
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsInferType
impl<V: ?Sized + Visit> VisitWith<V> for TsInferType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Bool
impl<V: ?Sized + Visit> VisitWith<V> for Bool
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for JSXClosingElement
impl<V: ?Sized + Visit> VisitWith<V> for JSXClosingElement
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsNamespaceExportDecl
impl<V: ?Sized + Visit> VisitWith<V> for TsNamespaceExportDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for EmptyStmt
impl<V: ?Sized + Visit> VisitWith<V> for EmptyStmt
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for PropName
impl<V: ?Sized + Visit> VisitWith<V> for PropName
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsLitType
impl<V: ?Sized + Visit> VisitWith<V> for TsLitType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for VarDecl
impl<V: ?Sized + Visit> VisitWith<V> for VarDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for WithStmt
impl<V: ?Sized + Visit> VisitWith<V> for WithStmt
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for [Stmt]
impl<V: ?Sized + Visit> VisitWith<V> for [Stmt]
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Vec<ExprOrSpread>
impl<V: ?Sized + Visit> VisitWith<V> for Vec<ExprOrSpread>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for JSXExprContainer
impl<V: ?Sized + Visit> VisitWith<V> for JSXExprContainer
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Vec<Stmt>
impl<V: ?Sized + Visit> VisitWith<V> for Vec<Stmt>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Constructor
impl<V: ?Sized + Visit> VisitWith<V> for Constructor
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ContinueStmt
impl<V: ?Sized + Visit> VisitWith<V> for ContinueStmt
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for JSXAttr
impl<V: ?Sized + Visit> VisitWith<V> for JSXAttr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsTypeParam
impl<V: ?Sized + Visit> VisitWith<V> for TsTypeParam
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Vec<ExprOrSpread>>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Vec<ExprOrSpread>>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsParenthesizedType
impl<V: ?Sized + Visit> VisitWith<V> for TsParenthesizedType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for JSXElementChild
impl<V: ?Sized + Visit> VisitWith<V> for JSXElementChild
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsTypeParamInstantiation
impl<V: ?Sized + Visit> VisitWith<V> for TsTypeParamInstantiation
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for BlockStmt
impl<V: ?Sized + Visit> VisitWith<V> for BlockStmt
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsFnParam
impl<V: ?Sized + Visit> VisitWith<V> for TsFnParam
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for JSXAttrOrSpread
impl<V: ?Sized + Visit> VisitWith<V> for JSXAttrOrSpread
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for YieldExpr
impl<V: ?Sized + Visit> VisitWith<V> for YieldExpr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for [TsFnParam]
impl<V: ?Sized + Visit> VisitWith<V> for [TsFnParam]
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsKeywordType
impl<V: ?Sized + Visit> VisitWith<V> for TsKeywordType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsThisType
impl<V: ?Sized + Visit> VisitWith<V> for TsThisType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsGetterSignature
impl<V: ?Sized + Visit> VisitWith<V> for TsGetterSignature
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Vec<TsTupleElement>
impl<V: ?Sized + Visit> VisitWith<V> for Vec<TsTupleElement>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ExportNamedSpecifier
impl<V: ?Sized + Visit> VisitWith<V> for ExportNamedSpecifier
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsIndexedAccessType
impl<V: ?Sized + Visit> VisitWith<V> for TsIndexedAccessType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ObjectPatProp
impl<V: ?Sized + Visit> VisitWith<V> for ObjectPatProp
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ThrowStmt
impl<V: ?Sized + Visit> VisitWith<V> for ThrowStmt
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for VarDeclKind
impl<V: ?Sized + Visit> VisitWith<V> for VarDeclKind
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsConstructSignatureDecl
impl<V: ?Sized + Visit> VisitWith<V> for TsConstructSignatureDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Vec<TplElement>
impl<V: ?Sized + Visit> VisitWith<V> for Vec<TplElement>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsInterfaceBody
impl<V: ?Sized + Visit> VisitWith<V> for TsInterfaceBody
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for PropOrSpread
impl<V: ?Sized + Visit> VisitWith<V> for PropOrSpread
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<TsTypeAnn>>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<TsTypeAnn>>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for [Box<Expr>]
impl<V: ?Sized + Visit> VisitWith<V> for [Box<Expr>]
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for AssignExpr
impl<V: ?Sized + Visit> VisitWith<V> for AssignExpr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ClassDecl
impl<V: ?Sized + Visit> VisitWith<V> for ClassDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsInterfaceDecl
impl<V: ?Sized + Visit> VisitWith<V> for TsInterfaceDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Number
impl<V: ?Sized + Visit> VisitWith<V> for Number
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsMappedType
impl<V: ?Sized + Visit> VisitWith<V> for TsMappedType
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsNamespaceDecl
impl<V: ?Sized + Visit> VisitWith<V> for TsNamespaceDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsModuleDecl
impl<V: ?Sized + Visit> VisitWith<V> for TsModuleDecl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ImportSpecifier
impl<V: ?Sized + Visit> VisitWith<V> for ImportSpecifier
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for BlockStmtOrExpr
impl<V: ?Sized + Visit> VisitWith<V> for BlockStmtOrExpr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for VarDeclarator
impl<V: ?Sized + Visit> VisitWith<V> for VarDeclarator
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ForInStmt
impl<V: ?Sized + Visit> VisitWith<V> for ForInStmt
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TsExprWithTypeArgs
impl<V: ?Sized + Visit> VisitWith<V> for TsExprWithTypeArgs
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Vec<JSXElementChild>
impl<V: ?Sized + Visit> VisitWith<V> for Vec<JSXElementChild>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for TaggedTpl
impl<V: ?Sized + Visit> VisitWith<V> for TaggedTpl
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ModuleItem
impl<V: ?Sized + Visit> VisitWith<V> for ModuleItem
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Vec<ModuleItem>
impl<V: ?Sized + Visit> VisitWith<V> for Vec<ModuleItem>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ClassMethod
impl<V: ?Sized + Visit> VisitWith<V> for ClassMethod
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Pat>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Pat>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for [TsTupleElement]
impl<V: ?Sized + Visit> VisitWith<V> for [TsTupleElement]
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<ModuleExportName>
impl<V: ?Sized + Visit> VisitWith<V> for Option<ModuleExportName>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for [Option<ExprOrSpread>]
impl<V: ?Sized + Visit> VisitWith<V> for [Option<ExprOrSpread>]
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for AwaitExpr
impl<V: ?Sized + Visit> VisitWith<V> for AwaitExpr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for ObjectLit
impl<V: ?Sized + Visit> VisitWith<V> for ObjectLit
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for FnExpr
impl<V: ?Sized + Visit> VisitWith<V> for FnExpr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for BinExpr
impl<V: ?Sized + Visit> VisitWith<V> for BinExpr
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<Str>>
impl<V: ?Sized + Visit> VisitWith<V> for Option<Box<Str>>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for Option<TruePlusMinus>
impl<V: ?Sized + Visit> VisitWith<V> for Option<TruePlusMinus>
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V: ?Sized + Visit> VisitWith<V> for [ExportSpecifier]
impl<V: ?Sized + Visit> VisitWith<V> for [ExportSpecifier]
fn visit_with(&self, v: &mut V)
fn visit_children_with(&self, _visitor: &mut V)
source§impl<V, T> VisitWith<V> for Box<T>where
V: ?Sized + Visit,
T: 'static + VisitWith<V>,
impl<V, T> VisitWith<V> for Box<T>where V: ?Sized + Visit, T: 'static + VisitWith<V>,
source§fn visit_children_with(&self, v: &mut V)
fn visit_children_with(&self, v: &mut V)
Visit children nodes of self with v