pub enum AstParentKind {
Show 216 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),
TsSatisfiesExpr(TsSatisfiesExprField),
ReservedUnused(ReservedUnusedField),
}
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)
TsSatisfiesExpr(TsSatisfiesExprField)
ReservedUnused(ReservedUnusedField)
Trait Implementations§
Source§impl Clone for AstParentKind
impl Clone for AstParentKind
Source§fn clone(&self) -> AstParentKind
fn clone(&self) -> AstParentKind
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for AstParentKind
impl Debug for AstParentKind
Source§impl Hash for AstParentKind
impl Hash for AstParentKind
Source§impl Ord for AstParentKind
impl Ord for AstParentKind
Source§fn cmp(&self, other: &AstParentKind) -> Ordering
fn cmp(&self, other: &AstParentKind) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl ParentKind for AstParentKind
impl ParentKind for AstParentKind
Source§impl PartialEq for AstParentKind
impl PartialEq for AstParentKind
Source§impl PartialOrd for AstParentKind
impl PartialOrd for AstParentKind
impl Copy for AstParentKind
impl Eq for AstParentKind
impl StructuralPartialEq for AstParentKind
Auto Trait Implementations§
impl Freeze for AstParentKind
impl RefUnwindSafe for AstParentKind
impl Send for AstParentKind
impl Sync for AstParentKind
impl Unpin for AstParentKind
impl UnwindSafe for AstParentKind
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
§impl<T> CallHasher for T
impl<T> CallHasher for T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more