Enum swc_plugin::ast::AstParentKind
[−]pub enum AstParentKind {
Show 214 variants
Class(ClassField),
ClassMember(ClassMemberField),
ClassProp(ClassPropField),
PrivateProp(PrivatePropField),
ClassMethod(ClassMethodField),
PrivateMethod(PrivateMethodField),
Constructor(ConstructorField),
Decorator(DecoratorField),
StaticBlock(StaticBlockField),
Decl(DeclField),
FnDecl(FnDeclField),
ClassDecl(ClassDeclField),
VarDecl(VarDeclField),
VarDeclarator(VarDeclaratorField),
Expr(ExprField),
ThisExpr(ThisExprField),
ArrayLit(ArrayLitField),
ObjectLit(ObjectLitField),
PropOrSpread(PropOrSpreadField),
SpreadElement(SpreadElementField),
UnaryExpr(UnaryExprField),
UpdateExpr(UpdateExprField),
BinExpr(BinExprField),
FnExpr(FnExprField),
ClassExpr(ClassExprField),
AssignExpr(AssignExprField),
MemberExpr(MemberExprField),
MemberProp(MemberPropField),
SuperPropExpr(SuperPropExprField),
SuperProp(SuperPropField),
CondExpr(CondExprField),
CallExpr(CallExprField),
NewExpr(NewExprField),
SeqExpr(SeqExprField),
ArrowExpr(ArrowExprField),
YieldExpr(YieldExprField),
MetaPropExpr(MetaPropExprField),
AwaitExpr(AwaitExprField),
Tpl(TplField),
TaggedTpl(TaggedTplField),
TplElement(TplElementField),
ParenExpr(ParenExprField),
Callee(CalleeField),
Super(SuperField),
Import(ImportField),
ExprOrSpread(ExprOrSpreadField),
BlockStmtOrExpr(BlockStmtOrExprField),
PatOrExpr(PatOrExprField),
OptChainExpr(OptChainExprField),
OptChainBase(OptChainBaseField),
OptCall(OptCallField),
Function(FunctionField),
Param(ParamField),
ParamOrTsParamProp(ParamOrTsParamPropField),
BindingIdent(BindingIdentField),
Ident(IdentField),
PrivateName(PrivateNameField),
JSXObject(JSXObjectField),
JSXMemberExpr(JSXMemberExprField),
JSXNamespacedName(JSXNamespacedNameField),
JSXEmptyExpr(JSXEmptyExprField),
JSXExprContainer(JSXExprContainerField),
JSXExpr(JSXExprField),
JSXSpreadChild(JSXSpreadChildField),
JSXElementName(JSXElementNameField),
JSXOpeningElement(JSXOpeningElementField),
JSXAttrOrSpread(JSXAttrOrSpreadField),
JSXClosingElement(JSXClosingElementField),
JSXAttr(JSXAttrField),
JSXAttrName(JSXAttrNameField),
JSXAttrValue(JSXAttrValueField),
JSXText(JSXTextField),
JSXElement(JSXElementField),
JSXElementChild(JSXElementChildField),
JSXFragment(JSXFragmentField),
JSXOpeningFragment(JSXOpeningFragmentField),
JSXClosingFragment(JSXClosingFragmentField),
Invalid(InvalidField),
Lit(LitField),
BigInt(BigIntField),
Str(StrField),
Bool(BoolField),
Null(NullField),
Regex(RegexField),
Number(NumberField),
Program(ProgramField),
Module(ModuleField),
Script(ScriptField),
ModuleItem(ModuleItemField),
ModuleDecl(ModuleDeclField),
ExportDefaultExpr(ExportDefaultExprField),
ExportDecl(ExportDeclField),
ImportDecl(ImportDeclField),
ExportAll(ExportAllField),
NamedExport(NamedExportField),
ExportDefaultDecl(ExportDefaultDeclField),
DefaultDecl(DefaultDeclField),
ImportSpecifier(ImportSpecifierField),
ImportDefaultSpecifier(ImportDefaultSpecifierField),
ImportStarAsSpecifier(ImportStarAsSpecifierField),
ImportNamedSpecifier(ImportNamedSpecifierField),
ExportSpecifier(ExportSpecifierField),
ExportNamespaceSpecifier(ExportNamespaceSpecifierField),
ExportDefaultSpecifier(ExportDefaultSpecifierField),
ModuleExportName(ModuleExportNameField),
ExportNamedSpecifier(ExportNamedSpecifierField),
Pat(PatField),
ArrayPat(ArrayPatField),
ObjectPat(ObjectPatField),
AssignPat(AssignPatField),
RestPat(RestPatField),
ObjectPatProp(ObjectPatPropField),
KeyValuePatProp(KeyValuePatPropField),
AssignPatProp(AssignPatPropField),
Prop(PropField),
KeyValueProp(KeyValuePropField),
AssignProp(AssignPropField),
GetterProp(GetterPropField),
SetterProp(SetterPropField),
MethodProp(MethodPropField),
PropName(PropNameField),
ComputedPropName(ComputedPropNameField),
BlockStmt(BlockStmtField),
Stmt(StmtField),
ExprStmt(ExprStmtField),
EmptyStmt(EmptyStmtField),
DebuggerStmt(DebuggerStmtField),
WithStmt(WithStmtField),
ReturnStmt(ReturnStmtField),
LabeledStmt(LabeledStmtField),
BreakStmt(BreakStmtField),
ContinueStmt(ContinueStmtField),
IfStmt(IfStmtField),
SwitchStmt(SwitchStmtField),
ThrowStmt(ThrowStmtField),
TryStmt(TryStmtField),
WhileStmt(WhileStmtField),
DoWhileStmt(DoWhileStmtField),
ForStmt(ForStmtField),
ForInStmt(ForInStmtField),
ForOfStmt(ForOfStmtField),
SwitchCase(SwitchCaseField),
CatchClause(CatchClauseField),
VarDeclOrPat(VarDeclOrPatField),
VarDeclOrExpr(VarDeclOrExprField),
TsTypeAnn(TsTypeAnnField),
TsTypeParamDecl(TsTypeParamDeclField),
TsTypeParam(TsTypeParamField),
TsTypeParamInstantiation(TsTypeParamInstantiationField),
TsParamProp(TsParamPropField),
TsParamPropParam(TsParamPropParamField),
TsQualifiedName(TsQualifiedNameField),
TsEntityName(TsEntityNameField),
TsTypeElement(TsTypeElementField),
TsCallSignatureDecl(TsCallSignatureDeclField),
TsConstructSignatureDecl(TsConstructSignatureDeclField),
TsPropertySignature(TsPropertySignatureField),
TsGetterSignature(TsGetterSignatureField),
TsSetterSignature(TsSetterSignatureField),
TsMethodSignature(TsMethodSignatureField),
TsIndexSignature(TsIndexSignatureField),
TsType(TsTypeField),
TsFnOrConstructorType(TsFnOrConstructorTypeField),
TsKeywordType(TsKeywordTypeField),
TsThisType(TsThisTypeField),
TsFnParam(TsFnParamField),
TsFnType(TsFnTypeField),
TsConstructorType(TsConstructorTypeField),
TsTypeRef(TsTypeRefField),
TsTypePredicate(TsTypePredicateField),
TsThisTypeOrIdent(TsThisTypeOrIdentField),
TsTypeQuery(TsTypeQueryField),
TsTypeQueryExpr(TsTypeQueryExprField),
TsImportType(TsImportTypeField),
TsTypeLit(TsTypeLitField),
TsArrayType(TsArrayTypeField),
TsTupleType(TsTupleTypeField),
TsTupleElement(TsTupleElementField),
TsOptionalType(TsOptionalTypeField),
TsRestType(TsRestTypeField),
TsUnionOrIntersectionType(TsUnionOrIntersectionTypeField),
TsUnionType(TsUnionTypeField),
TsIntersectionType(TsIntersectionTypeField),
TsConditionalType(TsConditionalTypeField),
TsInferType(TsInferTypeField),
TsParenthesizedType(TsParenthesizedTypeField),
TsTypeOperator(TsTypeOperatorField),
TsIndexedAccessType(TsIndexedAccessTypeField),
TsMappedType(TsMappedTypeField),
TsLitType(TsLitTypeField),
TsLit(TsLitField),
TsTplLitType(TsTplLitTypeField),
TsInterfaceDecl(TsInterfaceDeclField),
TsInterfaceBody(TsInterfaceBodyField),
TsExprWithTypeArgs(TsExprWithTypeArgsField),
TsTypeAliasDecl(TsTypeAliasDeclField),
TsEnumDecl(TsEnumDeclField),
TsEnumMember(TsEnumMemberField),
TsEnumMemberId(TsEnumMemberIdField),
TsModuleDecl(TsModuleDeclField),
TsNamespaceBody(TsNamespaceBodyField),
TsModuleBlock(TsModuleBlockField),
TsNamespaceDecl(TsNamespaceDeclField),
TsModuleName(TsModuleNameField),
TsImportEqualsDecl(TsImportEqualsDeclField),
TsModuleRef(TsModuleRefField),
TsExternalModuleRef(TsExternalModuleRefField),
TsExportAssignment(TsExportAssignmentField),
TsNamespaceExportDecl(TsNamespaceExportDeclField),
TsAsExpr(TsAsExprField),
TsTypeAssertion(TsTypeAssertionField),
TsNonNullExpr(TsNonNullExprField),
TsConstAssertion(TsConstAssertionField),
TsInstantiation(TsInstantiationField),
}
Variants
Class(ClassField)
ClassMember(ClassMemberField)
ClassProp(ClassPropField)
PrivateProp(PrivatePropField)
ClassMethod(ClassMethodField)
PrivateMethod(PrivateMethodField)
Constructor(ConstructorField)
Decorator(DecoratorField)
StaticBlock(StaticBlockField)
Decl(DeclField)
FnDecl(FnDeclField)
ClassDecl(ClassDeclField)
VarDecl(VarDeclField)
VarDeclarator(VarDeclaratorField)
Expr(ExprField)
ThisExpr(ThisExprField)
ArrayLit(ArrayLitField)
ObjectLit(ObjectLitField)
PropOrSpread(PropOrSpreadField)
SpreadElement(SpreadElementField)
UnaryExpr(UnaryExprField)
UpdateExpr(UpdateExprField)
BinExpr(BinExprField)
FnExpr(FnExprField)
ClassExpr(ClassExprField)
AssignExpr(AssignExprField)
MemberExpr(MemberExprField)
MemberProp(MemberPropField)
SuperPropExpr(SuperPropExprField)
SuperProp(SuperPropField)
CondExpr(CondExprField)
CallExpr(CallExprField)
NewExpr(NewExprField)
SeqExpr(SeqExprField)
ArrowExpr(ArrowExprField)
YieldExpr(YieldExprField)
MetaPropExpr(MetaPropExprField)
AwaitExpr(AwaitExprField)
Tpl(TplField)
TaggedTpl(TaggedTplField)
TplElement(TplElementField)
ParenExpr(ParenExprField)
Callee(CalleeField)
Super(SuperField)
Import(ImportField)
ExprOrSpread(ExprOrSpreadField)
BlockStmtOrExpr(BlockStmtOrExprField)
PatOrExpr(PatOrExprField)
OptChainExpr(OptChainExprField)
OptChainBase(OptChainBaseField)
OptCall(OptCallField)
Function(FunctionField)
Param(ParamField)
ParamOrTsParamProp(ParamOrTsParamPropField)
BindingIdent(BindingIdentField)
Ident(IdentField)
PrivateName(PrivateNameField)
JSXObject(JSXObjectField)
JSXMemberExpr(JSXMemberExprField)
JSXNamespacedName(JSXNamespacedNameField)
JSXEmptyExpr(JSXEmptyExprField)
JSXExprContainer(JSXExprContainerField)
JSXExpr(JSXExprField)
JSXSpreadChild(JSXSpreadChildField)
JSXElementName(JSXElementNameField)
JSXOpeningElement(JSXOpeningElementField)
JSXAttrOrSpread(JSXAttrOrSpreadField)
JSXClosingElement(JSXClosingElementField)
JSXAttr(JSXAttrField)
JSXAttrName(JSXAttrNameField)
JSXAttrValue(JSXAttrValueField)
JSXText(JSXTextField)
JSXElement(JSXElementField)
JSXElementChild(JSXElementChildField)
JSXFragment(JSXFragmentField)
JSXOpeningFragment(JSXOpeningFragmentField)
JSXClosingFragment(JSXClosingFragmentField)
Invalid(InvalidField)
Lit(LitField)
BigInt(BigIntField)
Str(StrField)
Bool(BoolField)
Null(NullField)
Regex(RegexField)
Number(NumberField)
Program(ProgramField)
Module(ModuleField)
Script(ScriptField)
ModuleItem(ModuleItemField)
ModuleDecl(ModuleDeclField)
ExportDefaultExpr(ExportDefaultExprField)
ExportDecl(ExportDeclField)
ImportDecl(ImportDeclField)
ExportAll(ExportAllField)
NamedExport(NamedExportField)
ExportDefaultDecl(ExportDefaultDeclField)
DefaultDecl(DefaultDeclField)
ImportSpecifier(ImportSpecifierField)
ImportDefaultSpecifier(ImportDefaultSpecifierField)
ImportStarAsSpecifier(ImportStarAsSpecifierField)
ImportNamedSpecifier(ImportNamedSpecifierField)
ExportSpecifier(ExportSpecifierField)
ExportNamespaceSpecifier(ExportNamespaceSpecifierField)
ExportDefaultSpecifier(ExportDefaultSpecifierField)
ModuleExportName(ModuleExportNameField)
ExportNamedSpecifier(ExportNamedSpecifierField)
Pat(PatField)
ArrayPat(ArrayPatField)
ObjectPat(ObjectPatField)
AssignPat(AssignPatField)
RestPat(RestPatField)
ObjectPatProp(ObjectPatPropField)
KeyValuePatProp(KeyValuePatPropField)
AssignPatProp(AssignPatPropField)
Prop(PropField)
KeyValueProp(KeyValuePropField)
AssignProp(AssignPropField)
GetterProp(GetterPropField)
SetterProp(SetterPropField)
MethodProp(MethodPropField)
PropName(PropNameField)
ComputedPropName(ComputedPropNameField)
BlockStmt(BlockStmtField)
Stmt(StmtField)
ExprStmt(ExprStmtField)
EmptyStmt(EmptyStmtField)
DebuggerStmt(DebuggerStmtField)
WithStmt(WithStmtField)
ReturnStmt(ReturnStmtField)
LabeledStmt(LabeledStmtField)
BreakStmt(BreakStmtField)
ContinueStmt(ContinueStmtField)
IfStmt(IfStmtField)
SwitchStmt(SwitchStmtField)
ThrowStmt(ThrowStmtField)
TryStmt(TryStmtField)
WhileStmt(WhileStmtField)
DoWhileStmt(DoWhileStmtField)
ForStmt(ForStmtField)
ForInStmt(ForInStmtField)
ForOfStmt(ForOfStmtField)
SwitchCase(SwitchCaseField)
CatchClause(CatchClauseField)
VarDeclOrPat(VarDeclOrPatField)
VarDeclOrExpr(VarDeclOrExprField)
TsTypeAnn(TsTypeAnnField)
TsTypeParamDecl(TsTypeParamDeclField)
TsTypeParam(TsTypeParamField)
TsTypeParamInstantiation(TsTypeParamInstantiationField)
TsParamProp(TsParamPropField)
TsParamPropParam(TsParamPropParamField)
TsQualifiedName(TsQualifiedNameField)
TsEntityName(TsEntityNameField)
TsTypeElement(TsTypeElementField)
TsCallSignatureDecl(TsCallSignatureDeclField)
TsConstructSignatureDecl(TsConstructSignatureDeclField)
TsPropertySignature(TsPropertySignatureField)
TsGetterSignature(TsGetterSignatureField)
TsSetterSignature(TsSetterSignatureField)
TsMethodSignature(TsMethodSignatureField)
TsIndexSignature(TsIndexSignatureField)
TsType(TsTypeField)
TsFnOrConstructorType(TsFnOrConstructorTypeField)
TsKeywordType(TsKeywordTypeField)
TsThisType(TsThisTypeField)
TsFnParam(TsFnParamField)
TsFnType(TsFnTypeField)
TsConstructorType(TsConstructorTypeField)
TsTypeRef(TsTypeRefField)
TsTypePredicate(TsTypePredicateField)
TsThisTypeOrIdent(TsThisTypeOrIdentField)
TsTypeQuery(TsTypeQueryField)
TsTypeQueryExpr(TsTypeQueryExprField)
TsImportType(TsImportTypeField)
TsTypeLit(TsTypeLitField)
TsArrayType(TsArrayTypeField)
TsTupleType(TsTupleTypeField)
TsTupleElement(TsTupleElementField)
TsOptionalType(TsOptionalTypeField)
TsRestType(TsRestTypeField)
TsUnionOrIntersectionType(TsUnionOrIntersectionTypeField)
TsUnionType(TsUnionTypeField)
TsIntersectionType(TsIntersectionTypeField)
TsConditionalType(TsConditionalTypeField)
TsInferType(TsInferTypeField)
TsParenthesizedType(TsParenthesizedTypeField)
TsTypeOperator(TsTypeOperatorField)
TsIndexedAccessType(TsIndexedAccessTypeField)
TsMappedType(TsMappedTypeField)
TsLitType(TsLitTypeField)
TsLit(TsLitField)
TsTplLitType(TsTplLitTypeField)
TsInterfaceDecl(TsInterfaceDeclField)
TsInterfaceBody(TsInterfaceBodyField)
TsExprWithTypeArgs(TsExprWithTypeArgsField)
TsTypeAliasDecl(TsTypeAliasDeclField)
TsEnumDecl(TsEnumDeclField)
TsEnumMember(TsEnumMemberField)
TsEnumMemberId(TsEnumMemberIdField)
TsModuleDecl(TsModuleDeclField)
TsNamespaceBody(TsNamespaceBodyField)
TsModuleBlock(TsModuleBlockField)
TsNamespaceDecl(TsNamespaceDeclField)
TsModuleName(TsModuleNameField)
TsImportEqualsDecl(TsImportEqualsDeclField)
TsModuleRef(TsModuleRefField)
TsExternalModuleRef(TsExternalModuleRefField)
TsExportAssignment(TsExportAssignmentField)
TsNamespaceExportDecl(TsNamespaceExportDeclField)
TsAsExpr(TsAsExprField)
TsTypeAssertion(TsTypeAssertionField)
TsNonNullExpr(TsNonNullExprField)
TsConstAssertion(TsConstAssertionField)
TsInstantiation(TsInstantiationField)
Trait Implementations
impl Clone for AstParentKind
impl Clone for AstParentKind
fn clone(&self) -> AstParentKind
fn clone(&self) -> AstParentKind
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Debug for AstParentKind
impl Debug for AstParentKind
impl<'de> Deserialize<'de> for AstParentKind
impl<'de> Deserialize<'de> for AstParentKind
fn deserialize<__D>(
__deserializer: __D
) -> Result<AstParentKind, <__D as Deserializer<'de>>::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<AstParentKind, <__D as Deserializer<'de>>::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Hash for AstParentKind
impl Hash for AstParentKind
impl Ord for AstParentKind
impl Ord for AstParentKind
impl ParentKind for AstParentKind
impl ParentKind for AstParentKind
impl PartialEq<AstParentKind> for AstParentKind
impl PartialEq<AstParentKind> for AstParentKind
fn eq(&self, other: &AstParentKind) -> bool
fn eq(&self, other: &AstParentKind) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
fn ne(&self, other: &AstParentKind) -> bool
fn ne(&self, other: &AstParentKind) -> bool
This method tests for !=
.
impl PartialOrd<AstParentKind> for AstParentKind
impl PartialOrd<AstParentKind> for AstParentKind
fn partial_cmp(&self, other: &AstParentKind) -> Option<Ordering>
fn partial_cmp(&self, other: &AstParentKind) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
impl Serialize for AstParentKind
impl Serialize for AstParentKind
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Copy for AstParentKind
impl Eq for AstParentKind
impl StructuralEq for AstParentKind
impl StructuralPartialEq for AstParentKind
Auto Trait Implementations
impl RefUnwindSafe for AstParentKind
impl Send for AstParentKind
impl Sync for AstParentKind
impl Unpin for AstParentKind
impl UnwindSafe for AstParentKind
Blanket Implementations
impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<F, W, T, D> Deserialize<With<T, W>, D> for F where
W: DeserializeWith<F, T, D>,
D: Fallible + ?Sized,
F: ?Sized,
impl<F, W, T, D> Deserialize<With<T, W>, D> for F where
W: DeserializeWith<F, T, D>,
D: Fallible + ?Sized,
F: ?Sized,
fn deserialize(
&self,
deserializer: &mut D
) -> Result<With<T, W>, <D as Fallible>::Error>
fn deserialize(
&self,
deserializer: &mut D
) -> Result<With<T, W>, <D as Fallible>::Error>
Deserializes using the given deserializer
sourceimpl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
sourcefn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to key
and return true
if they are equal.
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more