Expand description
Contains logic that makes viewing and transform parts of AST trivial through the visitor pattern
Structs§
- Annex
- Chain
- Contains
ChainVariables which signal the position in the AST - Visit
Options - Options for behavior when visiting AST. Customizable behavior is important for analysis
- Visitors
- A utility type which implements
VisitorReceiver. Use for running a bunch of different immutable visitors over a immutable AST. Used for simple analysis - Visitors
Mut - A utility type which implements
VisitorMutReceiver. Use for running a bunch of different mutable visitors over a mutable AST. Therefore can remove, add or change AST
Enums§
- Block
Item - Wrapper type for
StatementOrDeclaration. Needed becausecrate::Statementdoesn’t come underStatementOrDeclarationin the case ofcrate::BlockOrSingleStatement - Block
Item Mut - Wrapper type for
StatementOrDeclaration. Needed becausecrate::Statementdoesn’t come underStatementOrDeclarationin the case ofcrate::BlockOrSingleStatement - Chain
Variable - Immutable
Variable OrProperty - Mutable
Variable OrProperty
Traits§
- Self
Visitable - Yielded during visiting AST. Might not be 1:1 with AST and include a wrapping type
- Self
Visitable Mut - Yielded during visiting AST. Might not be 1:1 with AST and include a wrapping type
- Visitable
- For something to visitable it can visit all nested fields.
- Visitor
- A visitor over something which is hooked/is
SelfVisitablewith some genericData - Visitor
Mut - A visitor over something which is hooked/is
SelfVisitableMutwith some Data - Visitor
MutReceiver - These are a receiver traits of the visitor
- Visitor
Receiver - Something which has a bunch of callbacks for AST