Module ezno_parser::visiting
source · Expand description
Contains logic that makes viewing and transform parts of AST trivial through the visitor pattern
Structs§
- Contains
ChainVariable
s which signal the position in the AST - Options for behavior when visiting AST. Customizable behavior is important for analysis
- A utility type which implements
VisitorReceiver
. Use for running a bunch of different immutable visitors over a immutable AST. Used for simple analysis - 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§
- Wrapper type for
StatementOrDeclaration
. Needed becausecrate::Statement
doesn’t come underStatementOrDeclaration
in the case ofcrate::BlockOrSingleStatement
- Wrapper type for
StatementOrDeclaration
. Needed becausecrate::Statement
doesn’t come underStatementOrDeclaration
in the case ofcrate::BlockOrSingleStatement
Traits§
- Yielded during visiting AST. Might not be 1:1 with AST and include a wrapping type
- Yielded during visiting AST. Might not be 1:1 with AST and include a wrapping type
- For something to visitable it can visit all nested fields.
- A visitor over something which is hooked/is
SelfVisitable
with some genericData
- A visitor over something which is hooked/is
SelfVisitableMut
with some Data - These are a receiver traits of the visitor
- Something which has a bunch of callbacks for AST