Expand description
Pattern inference, matching, and validation.
This module contains the core algorithms for:
- Inference (
inferrer): Deriving transformation patterns from before/after example pairs by performing a structural diff of their ASTs. - Matching (
matcher): Finding occurrences of a pattern in arbitrary source code by comparing AST sub-trees. - Validation (
validator): Checking that an inferred pattern is well-formed and likely to produce correct transformations.
Re-exports§
pub use inferrer::PatternInferrer;pub use matcher::PatternMatcher;pub use validator::PatternValidator;
Modules§
Structs§
- Pattern
- Represents an inferred transformation pattern.
- Pattern
Var - Represents a pattern variable that matches any expression or identifier at a particular position in the AST.