Expand description
Filter predicates — comprehension_forms.md §10.9: their evaluation (§10.9.1) and their analysis.
A predicate is the text carried by
crate::iteration::comprehension::ast::Comprehension::Filter,
parsed by parse_predicate with the language’s one precedence
table. CompiledPredicate evaluates it against a tuple on every
path that filters and decides whether it is total. The analyzer
produces PredicateInfo from the same tree for the optimizer’s
R5 (per-axis filter pushdown).
§Module layout
eval—CompiledPredicate, the evaluator, and its totality check.info—PredicateInfoand supporting enums.coordset—CoordSetcarrying per-coord discrete / continuous classification.recognizers— the §10.9.5 pattern catalog.analyzer— entry point + dispatch.
Re-exports§
pub use analyzer::analyze;pub use coordset::CoordInfo;pub use coordset::CoordKind;pub use coordset::CoordSet;pub use eval::CompiledPredicate;pub use eval::ValueKind;pub use eval::element_kind;pub use info::Determinism;pub use info::Factorization;pub use info::Monotonicity;pub use info::OpaqueReason;pub use info::PerAxisMap;pub use info::PredicateInfo;pub use info::RangeConstraint;
Modules§
- analyzer
- Predicate analyzer entry point — comprehension_forms.md §10.9.2.
- coordset
- Coordinate set with per-coord classification — comprehension_forms.md §10.9.2.
- eval
- Evaluating a comprehension’s
wherepredicate against a tuple. - info
PredicateInfoand supporting enums — comprehension_forms.md §10.9.3.- recognizers
- Pattern recognizer catalog — comprehension_forms.md §10.9.5.
Structs§
- Predicate
- One node of a parsed predicate and the byte range of its text.
Enums§
- Comparison
- A comparison operator.
- Predicate
Kind - The kinds of predicate node.
- Predicate
Literal - A literal in a predicate.
Functions§
- parse_
predicate - Parse a predicate. An error names what the predicate grammar does not accept; the caller may still evaluate the whole text as a Polydat expression.