pub enum Expression {
Show 114 variants
AbstractLiteral(Metadata, AbstractLiteral<Expression>),
Root(Metadata, Vec<Expression>),
Bubble(Metadata, Moo<Expression>, Moo<Expression>),
Comprehension(Metadata, Moo<Comprehension>),
DominanceRelation(Metadata, Moo<Expression>),
FromSolution(Metadata, Moo<Atom>),
Metavar(Metadata, Ustr),
Atomic(Metadata, Atom),
TypeAnnotation(Metadata, Moo<Expression>, DomainPtr),
DomainAnnotation(Metadata, Moo<Expression>, DomainPtr),
Active(Metadata, Moo<Expression>, Name),
RecordField(Metadata, Moo<Expression>, Name),
UnsafeIndex(Metadata, Moo<Expression>, Vec<Expression>),
SafeIndex(Metadata, Moo<Expression>, Vec<Expression>),
UnsafeSlice(Metadata, Moo<Expression>, Vec<Option<Expression>>),
SafeSlice(Metadata, Moo<Expression>, Vec<Option<Expression>>),
InDomain(Metadata, Moo<Expression>, DomainPtr),
ToInt(Metadata, Moo<Expression>),
Abs(Metadata, Moo<Expression>),
Sum(Metadata, Moo<Expression>),
Product(Metadata, Moo<Expression>),
Min(Metadata, Moo<Expression>),
Max(Metadata, Moo<Expression>),
Not(Metadata, Moo<Expression>),
Or(Metadata, Moo<Expression>),
And(Metadata, Moo<Expression>),
Imply(Metadata, Moo<Expression>, Moo<Expression>),
Iff(Metadata, Moo<Expression>, Moo<Expression>),
Union(Metadata, Moo<Expression>, Moo<Expression>),
In(Metadata, Moo<Expression>, Moo<Expression>),
Intersect(Metadata, Moo<Expression>, Moo<Expression>),
Difference(Metadata, Moo<Expression>, Moo<Expression>),
Supset(Metadata, Moo<Expression>, Moo<Expression>),
SupsetEq(Metadata, Moo<Expression>, Moo<Expression>),
Subset(Metadata, Moo<Expression>, Moo<Expression>),
SubsetEq(Metadata, Moo<Expression>, Moo<Expression>),
Eq(Metadata, Moo<Expression>, Moo<Expression>),
Neq(Metadata, Moo<Expression>, Moo<Expression>),
Geq(Metadata, Moo<Expression>, Moo<Expression>),
Leq(Metadata, Moo<Expression>, Moo<Expression>),
Gt(Metadata, Moo<Expression>, Moo<Expression>),
Lt(Metadata, Moo<Expression>, Moo<Expression>),
Subsequence(Metadata, Moo<Expression>, Moo<Expression>),
Substring(Metadata, Moo<Expression>, Moo<Expression>),
CatchUndef(Metadata, Moo<Expression>, Moo<Expression>),
SafeDiv(Metadata, Moo<Expression>, Moo<Expression>),
UnsafeDiv(Metadata, Moo<Expression>, Moo<Expression>),
SafeMod(Metadata, Moo<Expression>, Moo<Expression>),
UnsafeMod(Metadata, Moo<Expression>, Moo<Expression>),
Neg(Metadata, Moo<Expression>),
Factorial(Metadata, Moo<Expression>),
Defined(Metadata, Moo<Expression>),
Range(Metadata, Moo<Expression>),
ToSet(Metadata, Moo<Expression>),
ToMSet(Metadata, Moo<Expression>),
ToRelation(Metadata, Moo<Expression>),
UnsafePow(Metadata, Moo<Expression>, Moo<Expression>),
SafePow(Metadata, Moo<Expression>, Moo<Expression>),
Flatten(Metadata, Option<Moo<Expression>>, Moo<Expression>),
AttributeAsConstraint(Metadata, Moo<Expression>, Ustr, Option<Moo<Expression>>),
AllDiff(Metadata, Moo<Expression>),
SmtDistinct(Metadata, Moo<Expression>),
AllDifferentExcept(Metadata, Moo<Expression>, Moo<Expression>),
ElementId(Metadata, Moo<Expression>, Moo<Expression>),
Table(Metadata, Moo<Expression>, Moo<Expression>),
NegativeTable(Metadata, Moo<Expression>, Moo<Expression>),
AtLeast(Metadata, Moo<Expression>, Moo<Expression>, Moo<Expression>),
AtMost(Metadata, Moo<Expression>, Moo<Expression>, Moo<Expression>),
Gcc(Metadata, Moo<Expression>, Moo<Expression>, Moo<Expression>),
GccWeak(Metadata, Moo<Expression>, Moo<Expression>, Moo<Expression>),
Minus(Metadata, Moo<Expression>, Moo<Expression>),
Apart(Metadata, Moo<Expression>, Moo<Expression>),
Participants(Metadata, Moo<Expression>),
Party(Metadata, Moo<Expression>, Moo<Expression>),
Parts(Metadata, Moo<Expression>),
Together(Metadata, Moo<Expression>, Moo<Expression>),
FlatAbsEq(Metadata, Moo<Atom>, Moo<Atom>),
FlatAllDiff(Metadata, Vec<Atom>),
FlatMinEq(Metadata, Vec<Atom>, Atom),
FlatSumGeq(Metadata, Vec<Atom>, Atom),
FlatSumLeq(Metadata, Vec<Atom>, Atom),
FlatIneq(Metadata, Moo<Atom>, Moo<Atom>, Box<Literal>),
FlatWatchedLiteral(Metadata, Reference, Literal),
FlatWeightedSumLeq(Metadata, Vec<Literal>, Vec<Atom>, Moo<Atom>),
FlatWeightedSumGeq(Metadata, Vec<Literal>, Vec<Atom>, Moo<Atom>),
FlatMinusEq(Metadata, Moo<Atom>, Moo<Atom>),
FlatProductEq(Metadata, Moo<Atom>, Moo<Atom>, Moo<Atom>),
MinionDivEqUndefZero(Metadata, Moo<Atom>, Moo<Atom>, Moo<Atom>),
MinionModuloEqUndefZero(Metadata, Moo<Atom>, Moo<Atom>, Moo<Atom>),
MinionPow(Metadata, Moo<Atom>, Moo<Atom>, Moo<Atom>),
MinionReify(Metadata, Moo<Expression>, Atom),
MinionReifyImply(Metadata, Moo<Expression>, Atom),
MinionWInIntervalSet(Metadata, Atom, Vec<i32>),
MinionWInSet(Metadata, Atom, Vec<i32>),
MinionElementOne(Metadata, Vec<Atom>, Moo<Atom>, Moo<Atom>),
AuxDeclaration(Metadata, Reference, Moo<Expression>),
SATInt(Metadata, SATIntEncoding, Moo<Expression>, (i32, i32)),
PairwiseSum(Metadata, Moo<Expression>, Moo<Expression>),
PairwiseProduct(Metadata, Moo<Expression>, Moo<Expression>),
Image(Metadata, Moo<Expression>, Moo<Expression>),
ImageSet(Metadata, Moo<Expression>, Moo<Expression>),
PreImage(Metadata, Moo<Expression>, Moo<Expression>),
Inverse(Metadata, Moo<Expression>, Moo<Expression>),
PermInverse(Metadata, Moo<Expression>),
Compose(Metadata, Moo<Expression>, Moo<Expression>),
Restrict(Metadata, Moo<Expression>, Moo<Expression>),
LexLt(Metadata, Moo<Expression>, Moo<Expression>),
LexLeq(Metadata, Moo<Expression>, Moo<Expression>),
LexGt(Metadata, Moo<Expression>, Moo<Expression>),
LexGeq(Metadata, Moo<Expression>, Moo<Expression>),
FlatLexLt(Metadata, Vec<Atom>, Vec<Atom>),
FlatLexLeq(Metadata, Vec<Atom>, Vec<Atom>),
RelationProj(Metadata, Moo<Expression>, Vec<Option<Expression>>),
Card(Metadata, Moo<Expression>),
}Expand description
Represents different types of expressions used to define rules and constraints in the model.
The Expression enum includes operations, constants, and variable references
used to build rules and conditions for the model.
§Compatability
§Minion
AuxDeclarationFlatAbsEqFlatAllDiffFlatIneqFlatMinEqFlatMinusEqFlatProductEqFlatSumGeqFlatSumLeqFlatWatchedLiteralGccWeakMinionDivEqUndefZeroMinionElementOneMinionModuloEqUndefZeroMinionReifyMinionReifyImplyMinionWInIntervalSetMinionWInSet
§SAT
§JsonInput
AbsActiveAllDiffAllDifferentExceptAndApartAtLeastAtMostCardCatchUndefComposeDefinedDifferenceEqFactorialGccGeqGtIffImageImageSetImplyInIntersectInverseLeqLtMaxMinMinusNegNegativeTableNeqNotOrParticipantsPartsPartyPermInversePreImageProductRangeRecordFieldRelationProjRestrictSubsequenceSubsetSubsetEqSubstringSumSupsetSupsetEqTableToMSetToRelationToSetTogetherUnionUnsafeDivUnsafeIndexUnsafeModUnsafePowUnsafeSlice
§SMT
Variants§
AbstractLiteral(Metadata, AbstractLiteral<Expression>)
Root(Metadata, Vec<Expression>)
The top of the model
Bubble(Metadata, Moo<Expression>, Moo<Expression>)
An expression representing “A is valid as long as B is true” Turns into a conjunction when it reaches a boolean context
Comprehension(Metadata, Moo<Comprehension>)
A comprehension.
The inside of the comprehension opens a new scope.
DominanceRelation(Metadata, Moo<Expression>)
Defines dominance (“Solution A is preferred over Solution B”)
FromSolution(Metadata, Moo<Atom>)
fromSolution(name) - Used in dominance relation definitions
Metavar(Metadata, Ustr)
Atomic(Metadata, Atom)
TypeAnnotation(Metadata, Moo<Expression>, DomainPtr)
Type annotation expression: expr :: type.
DomainAnnotation(Metadata, Moo<Expression>, DomainPtr)
Domain annotation expression: expr : domain.
Active(Metadata, Moo<Expression>, Name)
Asserts that the given variant of a variant expression is in use. See also: GroundDomain::Variant Supported by: JsonInput.
RecordField(Metadata, Moo<Expression>, Name)
Indexing into a record expression, e.g {foo = 1, bar = true}[foo]
See also: GroundDomain::Record
Supported by: JsonInput.
UnsafeIndex(Metadata, Moo<Expression>, Vec<Expression>)
A matrix index.
Defined iff the indices are within their respective index domains. Supported by: JsonInput.
SafeIndex(Metadata, Moo<Expression>, Vec<Expression>)
A safe matrix index.
See Expression::UnsafeIndex
Supported by: SMT.
UnsafeSlice(Metadata, Moo<Expression>, Vec<Option<Expression>>)
A matrix slice: a[indices].
One of the indicies may be None, representing the dimension of the matrix we want to take
a slice of. For example, for some 3d matrix a, a[1,..,2] has the indices
Some(1),None,Some(2).
It is assumed that the slice only has one “wild-card” dimension and thus is 1 dimensional.
Defined iff the defined indices are within their respective index domains. Supported by: JsonInput.
SafeSlice(Metadata, Moo<Expression>, Vec<Option<Expression>>)
A safe matrix slice: a[indices].
InDomain(Metadata, Moo<Expression>, DomainPtr)
inDomain(x,domain) iff x is in the domain domain.
This cannot be constructed from Essence input, nor passed to a solver: this expression is
mainly used during the conversion of UnsafeIndex and UnsafeSlice to SafeIndex and
SafeSlice respectively.
ToInt(Metadata, Moo<Expression>)
toInt(b) casts boolean expression b to an integer.
-
If b is false, then
toInt(b) == 0 -
If b is true, then
toInt(b) == 1Supported by: SMT.
Abs(Metadata, Moo<Expression>)
|x| - absolute value of x
Supported by: JsonInput, SMT.
Sum(Metadata, Moo<Expression>)
sum(<vec_expr>)
Supported by: JsonInput, SMT.
Product(Metadata, Moo<Expression>)
a * b * c * ...
Supported by: JsonInput, SMT.
Min(Metadata, Moo<Expression>)
min(<vec_expr>)
Supported by: JsonInput, SMT.
Max(Metadata, Moo<Expression>)
max(<vec_expr>)
Supported by: JsonInput, SMT.
Not(Metadata, Moo<Expression>)
not(a)
Supported by: JsonInput, SAT, SMT.
Or(Metadata, Moo<Expression>)
or(<vec_expr>)
Supported by: JsonInput, SAT, SMT.
And(Metadata, Moo<Expression>)
and(<vec_expr>)
Supported by: JsonInput, SAT, SMT.
Imply(Metadata, Moo<Expression>, Moo<Expression>)
Ensures that a->b (material implication).
Supported by: JsonInput, SMT.
Iff(Metadata, Moo<Expression>, Moo<Expression>)
iff(a, b) a <-> b
Supported by: JsonInput, SMT.
Union(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
In(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
Intersect(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
Difference(Metadata, Moo<Expression>, Moo<Expression>)
Set difference, a - b.
Spelled with minus in Essence, but kept apart from Expression::Minus: the two share a
symbol and nothing else, and overloading one node for both made every arithmetic rule have
to ask whether its operands were really sets.
Supported by: JsonInput.
Supset(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
SupsetEq(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
Subset(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
SubsetEq(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
Eq(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput, SMT.
Neq(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput, SMT.
Geq(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput, SMT.
Leq(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput, SMT.
Gt(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput, SMT.
Lt(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput, SMT.
Subsequence(Metadata, Moo<Expression>, Moo<Expression>)
s subsequence t tests whether the list of values taken by s occurs in the same order
in the list of values taken by t
Supported by: JsonInput.
Substring(Metadata, Moo<Expression>, Moo<Expression>)
s substring t tests whether the list of values taken by s occurs in the same order
and contiguously in the list of values taken by t
Supported by: JsonInput.
CatchUndef(Metadata, Moo<Expression>, Moo<Expression>)
catchUndef(e, d): e where e is defined, d where it is not.
Definedness is only known once the bubble rules have run, so this survives until then and is lowered against the bubble condition the inner expression produces. Supported by: JsonInput.
SafeDiv(Metadata, Moo<Expression>, Moo<Expression>)
Division after preventing division by zero, usually with a bubble Supported by: SMT.
UnsafeDiv(Metadata, Moo<Expression>, Moo<Expression>)
Division with a possibly undefined value (division by 0) Supported by: JsonInput.
SafeMod(Metadata, Moo<Expression>, Moo<Expression>)
Modulo after preventing mod 0, usually with a bubble Supported by: SMT.
UnsafeMod(Metadata, Moo<Expression>, Moo<Expression>)
Modulo with a possibly undefined value (mod 0) Supported by: JsonInput.
Neg(Metadata, Moo<Expression>)
Negation: -x
Supported by: JsonInput, SMT.
Factorial(Metadata, Moo<Expression>)
Factorial: x! or ’factorial(x)`
Supported by: JsonInput.
Defined(Metadata, Moo<Expression>)
Set of domain values function is defined for Supported by: JsonInput.
Range(Metadata, Moo<Expression>)
Set of codomain values function is defined for Supported by: JsonInput.
ToSet(Metadata, Moo<Expression>)
Supported by: JsonInput.
ToMSet(Metadata, Moo<Expression>)
Supported by: JsonInput.
ToRelation(Metadata, Moo<Expression>)
Supported by: JsonInput.
UnsafePow(Metadata, Moo<Expression>, Moo<Expression>)
Unsafe powerx**y (possibly undefined)
Defined when (X!=0 \/ Y!=0) /\ Y>=0 Supported by: JsonInput.
SafePow(Metadata, Moo<Expression>, Moo<Expression>)
UnsafePow after preventing undefinedness
Flatten(Metadata, Option<Moo<Expression>>, Moo<Expression>)
Flatten matrix operator
flatten(M) or flatten(n, M)
where M is a matrix and n is an optional integer argument indicating depth of flattening
AttributeAsConstraint(Metadata, Moo<Expression>, Ustr, Option<Moo<Expression>>)
An attribute predicate used as a constraint, e.g. reflexive(r) or size(s, 3).
Lifted into the target’s declaration domain attributes when possible (see
passes::attribute_as_constraint); expanded in place to the equivalent formula otherwise.
AllDiff(Metadata, Moo<Expression>)
allDifferent(<vec_expr>)
Supported by: JsonInput.
SmtDistinct(Metadata, Moo<Expression>)
Z3’s native distinct over the elements of <vec_expr>.
This is emitted for the SMT backend only, and never appears in a model bound for any other
solver. It exists so that “hand allDifferent to Z3 as distinct” and “encode
allDifferent explicitly” are two rules competing at the same choice site, which is what
lets the heuristics pick between them – and what records the choice in the model, so it is
not asked again every time the expression is visited.
Supported by: SMT.
AllDifferentExcept(Metadata, Moo<Expression>, Moo<Expression>)
allDifferentExcept(<matrix>, <except>)
Supported by: JsonInput.
ElementId(Metadata, Moo<Expression>, Moo<Expression>)
elementId(<matrix>, <value>) — 1-based index of value in matrix
Table(Metadata, Moo<Expression>, Moo<Expression>)
table([x1, x2, ...], [[r11, r12, ...], [r21, r22, ...], ...])
Represents a positive table constraint: the tuple [x1, x2, ...] must match one of the
allowed rows.
Supported by: JsonInput.
NegativeTable(Metadata, Moo<Expression>, Moo<Expression>)
negativeTable([x1, x2, ...], [[r11, r12, ...], [r21, r22, ...], ...])
Represents a negative table constraint: the tuple [x1, x2, ...] must NOT match any of the
forbidden rows.
Supported by: JsonInput.
AtLeast(Metadata, Moo<Expression>, Moo<Expression>, Moo<Expression>)
atleast(vars, counts, values)
For each values[i], requires at least counts[i] occurrences in vars.
Supported by: JsonInput.
AtMost(Metadata, Moo<Expression>, Moo<Expression>, Moo<Expression>)
atmost(vars, counts, values)
For each values[i], requires at most counts[i] occurrences in vars.
Supported by: JsonInput.
Gcc(Metadata, Moo<Expression>, Moo<Expression>, Moo<Expression>)
gcc(vars, values, counts)
Global cardinality constraint. For each values[i], requires exactly counts[i]
occurrences in vars.
Supported by: JsonInput.
GccWeak(Metadata, Moo<Expression>, Moo<Expression>, Moo<Expression>)
Minion gccweak(vars, values, counts) — weaker propagation variant of gcc.
Supported by: Minion.
Minus(Metadata, Moo<Expression>, Moo<Expression>)
Binary subtraction operator
This is a parser-level construct, and is immediately normalised to Sum([a,-b]).
TODO: make this compatible with Set Difference calculations - need to change return type and domain for this expression and write a set comprehension rule.
have already edited minus_to_sum to prevent this from applying to sets
Supported by: JsonInput.
Apart(Metadata, Moo<Expression>, Moo<Expression>)
Partition Operator: test if a list of elements are not all contained in one part of the partition First Expr Arg is a list of elements Second Expr Arg is the partition Supported by: JsonInput.
Participants(Metadata, Moo<Expression>)
Partition Operator: union of all parts of a partition Expr Arg is a partition Supported by: JsonInput.
Party(Metadata, Moo<Expression>, Moo<Expression>)
Partition Operator: part of partition that contains specified element First Expr Arg is an element that should be contained Second Expr Arg is the partition that should contain that element Supported by: JsonInput.
Parts(Metadata, Moo<Expression>)
Partition Operator: partition to its set of parts Expr Arg is the partition from which the parts come from Supported by: JsonInput.
Together(Metadata, Moo<Expression>, Moo<Expression>)
Partition Operator: test if a list of elements are all in the same part of the partition First Expr Arg is the list of elements to test with Second Expr Arg is the partition to test on Supported by: JsonInput.
FlatAbsEq(Metadata, Moo<Atom>, Moo<Atom>)
Ensures that x=|y| i.e. x is the absolute value of y.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
FlatAllDiff(Metadata, Vec<Atom>)
Ensures that alldiff([a,b,...]).
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
FlatMinEq(Metadata, Vec<Atom>, Atom)
Ensures that result = min(vars).
Low-level Minion constraint. Prefer this over expanding Expression::Min into
leq/or/eq constraints when targeting Minion.
§See also
- Minion documentation Supported by: Minion.
FlatSumGeq(Metadata, Vec<Atom>, Atom)
Ensures that sum(vec) >= x.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
FlatSumLeq(Metadata, Vec<Atom>, Atom)
Ensures that sum(vec) <= x.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
FlatIneq(Metadata, Moo<Atom>, Moo<Atom>, Box<Literal>)
ineq(x,y,k) ensures that x <= y + k.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
FlatWatchedLiteral(Metadata, Reference, Literal)
w-literal(x,k) ensures that x == k, where x is a variable and k a constant.
Low-level Minion constraint.
This is a low-level Minion constraint and you should probably use Eq instead. The main use of w-literal is to convert boolean variables to constraints so that they can be used inside watched-and and watched-or.
§See also
- Minion documentation
rules::minion::boolean_literal_to_wliteral. Supported by: Minion.
FlatWeightedSumLeq(Metadata, Vec<Literal>, Vec<Atom>, Moo<Atom>)
weightedsumleq(cs,xs,total) ensures that cs.xs <= total, where cs.xs is the scalar dot
product of cs and xs.
Low-level Minion constraint.
Represents a weighted sum of the form ax + by + cz + ...
§See also
FlatWeightedSumGeq(Metadata, Vec<Literal>, Vec<Atom>, Moo<Atom>)
weightedsumgeq(cs,xs,total) ensures that cs.xs >= total, where cs.xs is the scalar dot
product of cs and xs.
Low-level Minion constraint.
Represents a weighted sum of the form ax + by + cz + ...
§See also
FlatMinusEq(Metadata, Moo<Atom>, Moo<Atom>)
Ensures that x =-y, where x and y are atoms.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
FlatProductEq(Metadata, Moo<Atom>, Moo<Atom>, Moo<Atom>)
Ensures that x*y=z.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
MinionDivEqUndefZero(Metadata, Moo<Atom>, Moo<Atom>, Moo<Atom>)
Ensures that floor(x/y)=z. Always true when y=0.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
MinionModuloEqUndefZero(Metadata, Moo<Atom>, Moo<Atom>, Moo<Atom>)
Ensures that x%y=z. Always true when y=0.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
MinionPow(Metadata, Moo<Atom>, Moo<Atom>, Moo<Atom>)
Ensures that x**y = z.
Low-level Minion constraint.
This constraint is false when y<0 except for 1**y=1 and (-1)**y=z (where z is 1 if y
is odd and z is -1 if y is even).
§See also
MinionReify(Metadata, Moo<Expression>, Atom)
reify(constraint,r) ensures that r=1 iff constraint is satisfied, where r is a 0/1
variable.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
MinionReifyImply(Metadata, Moo<Expression>, Atom)
reifyimply(constraint,r) ensures that r->constraint, where r is a 0/1 variable.
variable.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
MinionWInIntervalSet(Metadata, Atom, Vec<i32>)
w-inintervalset(x, [a1,a2, b1,b2, … ]) ensures that the value of x belongs to one of the
intervals {a1,…,a2}, {b1,…,b2} etc.
The list of intervals must be given in numerical order.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
MinionWInSet(Metadata, Atom, Vec<i32>)
w-inset(x, [v1, v2, … ]) ensures that the value of x is one of the explicitly given values v1, v2, etc.
This constraint enforces membership in a specific set of discrete values rather than intervals.
The list of values must be given in numerical order.
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
MinionElementOne(Metadata, Vec<Atom>, Moo<Atom>, Moo<Atom>)
element_one(vec, i, e) specifies that vec[i] = e. This implies that i is
in the range [1..len(vec)].
Low-level Minion constraint.
§See also
- Minion documentation Supported by: Minion.
AuxDeclaration(Metadata, Reference, Moo<Expression>)
Declaration of an auxiliary variable.
As with Savile Row, we semantically distinguish this from Eq.
Supported by: Minion.
SATInt(Metadata, SATIntEncoding, Moo<Expression>, (i32, i32))
This expression is for encoding ints for the SAT solver, it stores the encoding type, the vector of booleans and the min/max for the int. Supported by: SAT.
PairwiseSum(Metadata, Moo<Expression>, Moo<Expression>)
Addition over a pair of expressions (i.e. a + b) rather than a vec-expr like Expression::Sum. This is for compatibility with backends that do not support addition over vectors. Supported by: SMT.
PairwiseProduct(Metadata, Moo<Expression>, Moo<Expression>)
Multiplication over a pair of expressions (i.e. a * b) rather than a vec-expr like Expression::Product. This is for compatibility with backends that do not support multiplication over vectors. Supported by: SMT.
Image(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
ImageSet(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
PreImage(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
Inverse(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
PermInverse(Metadata, Moo<Expression>)
permInverse(p): the inverse of permutation p, as a new permutation value. Not to be
confused with Expression::Inverse, which is a boolean predicate over a pair of
permutations, not a value-returning operator.
Supported by: JsonInput.
Compose(Metadata, Moo<Expression>, Moo<Expression>)
compose(g, h): the permutation obtained by applying h then g, as a new permutation
value (image(compose(g, h), i) = image(g, image(h, i))).
Supported by: JsonInput.
Restrict(Metadata, Moo<Expression>, Moo<Expression>)
Supported by: JsonInput.
LexLt(Metadata, Moo<Expression>, Moo<Expression>)
Lexicographical < between two matrices.
A <lex B iff: A[i] < B[i] for some i /\ (A[j] > B[j] for some j -> i < j) I.e. A must be less than B at some index i, and if it is greater than B at another index j, then j comes after i. I.e. A must be greater than B at the first index where they differ.
E.g. [1, 1] <lex [2, 1] and [1, 1] <lex [1, 2]
LexLeq(Metadata, Moo<Expression>, Moo<Expression>)
Lexicographical <= between two matrices
LexGt(Metadata, Moo<Expression>, Moo<Expression>)
Lexicographical > between two matrices This is a parser-level construct, and is immediately normalised to LexLt(b, a)
LexGeq(Metadata, Moo<Expression>, Moo<Expression>)
Lexicographical >= between two matrices This is a parser-level construct, and is immediately normalised to LexLeq(b, a)
FlatLexLt(Metadata, Vec<Atom>, Vec<Atom>)
Low-level minion constraint. See Expression::LexLt
FlatLexLeq(Metadata, Vec<Atom>, Vec<Atom>)
Low-level minion constraint. See Expression::LexLeq
RelationProj(Metadata, Moo<Expression>, Vec<Option<Expression>>)
Alters the shape of relations by projection Supported by: JsonInput.
Card(Metadata, Moo<Expression>)
Cardinality of a collection type Supported by: JsonInput.
Implementations§
Source§impl Expression
impl Expression
Sourcepub fn domain_of(&self) -> Option<DomainPtr>
pub fn domain_of(&self) -> Option<DomainPtr>
Returns the possible values of the expression, recursing to leaf expressions.
Cached in this node’s own Metadata: domain_of_uncached recomputes recursively from
scratch with no memoisation of its own, so repeatedly calling domain_of on the same
subtree (as rules that check “is this operand scalar/abstract” tend to, once per rule
attempt) is quadratic in the worst case without a cache. The cache is invalidated when
this expression or a descendant changes.
Sourcepub fn meta_ref(&self) -> &Metadata
pub fn meta_ref(&self) -> &Metadata
Returns a reference to this expression’s metadata without cloning.
pub fn get_meta(&self) -> Metadata
pub fn set_meta(&self, meta: Metadata)
Sourcepub fn is_safe(&self) -> bool
pub fn is_safe(&self) -> bool
Checks whether this expression is safe.
An expression is unsafe if can be undefined, or if any of its children can be undefined.
Unsafe expressions are (typically) prefixed with Unsafe in our AST, and can be made safe through the use of bubble rules.
Sourcepub fn is_associative_commutative_operator(&self) -> bool
pub fn is_associative_commutative_operator(&self) -> bool
True if the expression is an associative and commutative operator
Sourcepub fn is_matrix_literal(&self) -> bool
pub fn is_matrix_literal(&self) -> bool
True if the expression is a matrix literal.
This is true for both forms of matrix literals: those with elements of type Literal and
Expression.
Sourcepub fn identical_atom_to(&self, other: &Expression) -> bool
pub fn identical_atom_to(&self, other: &Expression) -> bool
True iff self and other are both atomic and identical.
This method is useful to cheaply check equivalence. Assuming CSE is enabled, any unifiable
expressions will be rewritten to a common variable. This is much cheaper than checking the
entire subtrees of self and other.
Sourcepub fn unwrap_list_ref(&self) -> Option<&[Expression]>
pub fn unwrap_list_ref(&self) -> Option<&[Expression]>
If the expression is a list, borrows the inner expressions.
Prefer this over Expression::unwrap_list when the elements are only inspected: copying
them costs the whole list, which matters on wide matrices that rules test on every visit.
Unlike Expression::unwrap_list, a matrix held as an Atom::Literal is not unwrapped,
since its elements are literals with no Expression to borrow.
Sourcepub fn unwrap_list_cow(&self) -> Option<Cow<'_, [Expression]>>
pub fn unwrap_list_cow(&self) -> Option<Cow<'_, [Expression]>>
If the expression is a list, borrows the inner expressions where it can.
This accepts exactly the same expressions as Expression::unwrap_list, but avoids the
copy in the common case. Only a matrix held as an Atom::Literal allocates, because its
elements are literals that have to be materialised as Expressions; every other list
borrows.
Prefer this over Expression::unwrap_list when the elements are usually only inspected,
and over Expression::unwrap_list_ref when the narrower set of accepted expressions
would change behaviour.
Sourcepub fn list_len(&self) -> Option<usize>
pub fn list_len(&self) -> Option<usize>
Returns the number of elements when this expression is a list, without cloning them.
Unlike Expression::unwrap_list, this never converts literal elements into expressions.
Use it for length, emptiness, and list-shape checks.
Sourcepub fn is_list(&self) -> bool
pub fn is_list(&self) -> bool
Whether this expression is a list, without cloning or materialising its elements.
Sourcepub fn unwrap_list(&self) -> Option<Vec<Expression>>
pub fn unwrap_list(&self) -> Option<Vec<Expression>>
If the expression is a list, returns a copied vector of the inner expressions.
A list is any a matrix with the domain int(1..). This includes matrix literals without
any explicitly specified domain.
The vector is owned: a matrix stored inside Atom::Literal holds Literals that have
to be materialised as Expressions, and callers that rewrite the elements need them by
value. For inspection use Expression::unwrap_list_cow; for shape checks use
Expression::list_len or Expression::is_list.
Sourcepub fn into_list(self) -> Option<Vec<Expression>>
pub fn into_list(self) -> Option<Vec<Expression>>
If the expression is a list, consumes it and returns its elements.
Prefer this over Expression::unwrap_list when the expression is already owned: it moves
expression elements out of the matrix rather than cloning the complete list.
Sourcepub fn unwrap_matrix_unchecked_ref(&self) -> Option<(&[Expression], &DomainPtr)>
pub fn unwrap_matrix_unchecked_ref(&self) -> Option<(&[Expression], &DomainPtr)>
If the expression is an expression-valued matrix, borrows its elements and index domain.
As with Expression::unwrap_matrix_unchecked, callers must preserve the relationship
between the domain and element count. Literal-valued matrices are excluded because their
elements cannot be borrowed as Expressions.
Sourcepub fn unwrap_matrix_unchecked(self) -> Option<(Vec<Expression>, DomainPtr)>
pub fn unwrap_matrix_unchecked(self) -> Option<(Vec<Expression>, DomainPtr)>
If the expression is a matrix, gets it elements and index domain.
Consider using the safer Expression::unwrap_list instead.
It is generally undefined to edit the length of a matrix unless it is a list (as defined by
Expression::unwrap_list). Users of this function should ensure that, if the matrix is
reconstructed, the index domain and the number of elements in the matrix remain the same.
Sourcepub fn extend_root(self, exprs: Vec<Expression>) -> Expression
pub fn extend_root(self, exprs: Vec<Expression>) -> Expression
For a Root expression, extends the inner vec with the given vec.
§Panics
Panics if the expression is not Root.
Sourcepub fn into_literal(self) -> Option<Literal>
pub fn into_literal(self) -> Option<Literal>
Converts the expression to a literal, if possible.
Sourcepub fn to_ac_operator_kind(&self) -> Option<ACOperatorKind>
pub fn to_ac_operator_kind(&self) -> Option<ACOperatorKind>
If this expression is an associative-commutative operator, return its ACOperatorKind.
Sourcepub fn try_return_type(&self) -> Option<ReturnType>
pub fn try_return_type(&self) -> Option<ReturnType>
Typeable::return_type, where the type can be worked out.
return_type panics for a reference whose declaration has no domain yet – a value letting
whose body is not yet a constant, say. Parsers cannot rule those out while building the
model, so they ask this instead and read None as “unknown”.
Sourcepub fn universe_categories(&self) -> HashSet<Category>
pub fn universe_categories(&self) -> HashSet<Category>
Returns the categories of all sub-expressions of self.
Source§impl Expression
impl Expression
Sourcepub fn for_each_expr_child<'a>(&'a self, f: &mut impl FnMut(&'a Expression))
pub fn for_each_expr_child<'a>(&'a self, f: &mut impl FnMut(&'a Expression))
Visit each direct Expression child by reference, without cloning.
Sourcepub fn for_each_expression<'a>(&'a self, f: &mut impl FnMut(&'a Expression))
pub fn for_each_expression<'a>(&'a self, f: &mut impl FnMut(&'a Expression))
Visits this expression and all of its expression descendants by reference.
Sourcepub fn any_expression(&self, predicate: impl FnMut(&Expression) -> bool) -> bool
pub fn any_expression(&self, predicate: impl FnMut(&Expression) -> bool) -> bool
Returns whether this expression or any expression below it satisfies predicate.
Unlike [Uniplate::universe], this does not construct an owned copy of the traversed tree.
Sourcepub fn any_expression_descendant(
&self,
predicate: impl FnMut(&Expression) -> bool,
) -> bool
pub fn any_expression_descendant( &self, predicate: impl FnMut(&Expression) -> bool, ) -> bool
Returns whether any expression strictly below this one satisfies predicate.
Trait Implementations§
Source§impl Biplate<AbstractLiteral<Expression>> for Expression
impl Biplate<AbstractLiteral<Expression>> for Expression
Source§fn biplate(
&self,
) -> (Tree<AbstractLiteral<Expression>>, Box<dyn Fn(Tree<AbstractLiteral<Expression>>) -> Expression>)
fn biplate( &self, ) -> (Tree<AbstractLiteral<Expression>>, Box<dyn Fn(Tree<AbstractLiteral<Expression>>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<AbstractLiteral<Literal>> for Expression
impl Biplate<AbstractLiteral<Literal>> for Expression
Source§fn biplate(
&self,
) -> (Tree<AbstractLiteral<Literal>>, Box<dyn Fn(Tree<AbstractLiteral<Literal>>) -> Expression>)
fn biplate( &self, ) -> (Tree<AbstractLiteral<Literal>>, Box<dyn Fn(Tree<AbstractLiteral<Literal>>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Atom> for Expression
impl Biplate<Atom> for Expression
Source§fn biplate(&self) -> (Tree<Atom>, Box<dyn Fn(Tree<Atom>) -> Expression>)
fn biplate(&self) -> (Tree<Atom>, Box<dyn Fn(Tree<Atom>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Comprehension> for Expression
impl Biplate<Comprehension> for Expression
Source§fn biplate(
&self,
) -> (Tree<Comprehension>, Box<dyn Fn(Tree<Comprehension>) -> Expression>)
fn biplate( &self, ) -> (Tree<Comprehension>, Box<dyn Fn(Tree<Comprehension>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<DeclarationPtr> for Expression
impl Biplate<DeclarationPtr> for Expression
Source§fn biplate(
&self,
) -> (Tree<DeclarationPtr>, Box<dyn Fn(Tree<DeclarationPtr>) -> Expression>)
fn biplate( &self, ) -> (Tree<DeclarationPtr>, Box<dyn Fn(Tree<DeclarationPtr>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for Atom
impl Biplate<Expression> for Atom
Source§fn biplate(&self) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Atom>)
fn biplate(&self) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Atom>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for ComprehensionQualifier
impl Biplate<Expression> for ComprehensionQualifier
Source§fn biplate(
&self,
) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> ComprehensionQualifier>)
fn biplate( &self, ) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> ComprehensionQualifier>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for Comprehension
impl Biplate<Expression> for Comprehension
Source§fn biplate(
&self,
) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Comprehension>)
fn biplate( &self, ) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Comprehension>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for Declaration
impl Biplate<Expression> for Declaration
Source§fn biplate(
&self,
) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Declaration>)
fn biplate( &self, ) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Declaration>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for DeclarationKind
impl Biplate<Expression> for DeclarationKind
Source§fn biplate(
&self,
) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> DeclarationKind>)
fn biplate( &self, ) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> DeclarationKind>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for Domain
impl Biplate<Expression> for Domain
Source§fn biplate(&self) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Domain>)
fn biplate(&self) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Domain>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for IntVal
impl Biplate<Expression> for IntVal
Source§fn biplate(&self) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> IntVal>)
fn biplate(&self) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> IntVal>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for UnresolvedDomain
impl Biplate<Expression> for UnresolvedDomain
Source§fn biplate(
&self,
) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> UnresolvedDomain>)
fn biplate( &self, ) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> UnresolvedDomain>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for Expression
impl Biplate<Expression> for Expression
Source§fn biplate(
&self,
) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Expression>)
fn biplate( &self, ) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Expression>)
Source§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read moreSource§fn try_replace_child_at_bi(&mut self, index: usize, child: Expression) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: Expression) -> bool
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for Literal
impl Biplate<Expression> for Literal
Source§fn biplate(
&self,
) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Literal>)
fn biplate( &self, ) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Literal>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for Model
impl Biplate<Expression> for Model
Source§fn biplate(&self) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Self>)
fn biplate(&self) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Self>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Expression> for SymbolTable
impl Biplate<Expression> for SymbolTable
Source§fn biplate(&self) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Self>)
fn biplate(&self) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Self>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Field<Expression>> for Expression
impl Biplate<Field<Expression>> for Expression
Source§fn biplate(
&self,
) -> (Tree<Field<Expression>>, Box<dyn Fn(Tree<Field<Expression>>) -> Expression>)
fn biplate( &self, ) -> (Tree<Field<Expression>>, Box<dyn Fn(Tree<Field<Expression>>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Field<Literal>> for Expression
impl Biplate<Field<Literal>> for Expression
Source§fn biplate(
&self,
) -> (Tree<Field<Literal>>, Box<dyn Fn(Tree<Field<Literal>>) -> Expression>)
fn biplate( &self, ) -> (Tree<Field<Literal>>, Box<dyn Fn(Tree<Field<Literal>>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Literal> for Expression
impl Biplate<Literal> for Expression
Source§fn biplate(&self) -> (Tree<Literal>, Box<dyn Fn(Tree<Literal>) -> Expression>)
fn biplate(&self) -> (Tree<Literal>, Box<dyn Fn(Tree<Literal>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Metadata> for Expression
impl Biplate<Metadata> for Expression
Source§fn biplate(&self) -> (Tree<Metadata>, Box<dyn Fn(Tree<Metadata>) -> Expression>)
fn biplate(&self) -> (Tree<Metadata>, Box<dyn Fn(Tree<Metadata>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Model> for Expression
impl Biplate<Model> for Expression
Source§fn biplate(&self) -> (Tree<Model>, Box<dyn Fn(Tree<Model>) -> Expression>)
fn biplate(&self) -> (Tree<Model>, Box<dyn Fn(Tree<Model>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Moo<Domain>> for Expression
impl Biplate<Moo<Domain>> for Expression
Source§fn biplate(
&self,
) -> (Tree<DomainPtr>, Box<dyn Fn(Tree<DomainPtr>) -> Expression>)
fn biplate( &self, ) -> (Tree<DomainPtr>, Box<dyn Fn(Tree<DomainPtr>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Name> for Expression
impl Biplate<Name> for Expression
Source§fn biplate(&self) -> (Tree<Name>, Box<dyn Fn(Tree<Name>) -> Expression>)
fn biplate(&self) -> (Tree<Name>, Box<dyn Fn(Tree<Name>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Option<Expression>> for Expression
impl Biplate<Option<Expression>> for Expression
Source§fn biplate(
&self,
) -> (Tree<Option<Expression>>, Box<dyn Fn(Tree<Option<Expression>>) -> Expression>)
fn biplate( &self, ) -> (Tree<Option<Expression>>, Box<dyn Fn(Tree<Option<Expression>>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Reference> for Expression
impl Biplate<Reference> for Expression
Source§fn biplate(
&self,
) -> (Tree<Reference>, Box<dyn Fn(Tree<Reference>) -> Expression>)
fn biplate( &self, ) -> (Tree<Reference>, Box<dyn Fn(Tree<Reference>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<SymbolTable> for Expression
impl Biplate<SymbolTable> for Expression
Source§fn biplate(
&self,
) -> (Tree<SymbolTable>, Box<dyn Fn(Tree<SymbolTable>) -> Expression>)
fn biplate( &self, ) -> (Tree<SymbolTable>, Box<dyn Fn(Tree<SymbolTable>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<SymbolTablePtr> for Expression
impl Biplate<SymbolTablePtr> for Expression
Source§fn biplate(
&self,
) -> (Tree<SymbolTablePtr>, Box<dyn Fn(Tree<SymbolTablePtr>) -> Expression>)
fn biplate( &self, ) -> (Tree<SymbolTablePtr>, Box<dyn Fn(Tree<SymbolTablePtr>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl Biplate<Vec<Expression>> for Expression
impl Biplate<Vec<Expression>> for Expression
Source§fn biplate(
&self,
) -> (Tree<Vec<Expression>>, Box<dyn Fn(Tree<Vec<Expression>>) -> Expression>)
fn biplate( &self, ) -> (Tree<Vec<Expression>>, Box<dyn Fn(Tree<Vec<Expression>>) -> Expression>)
§fn with_children_bi(&self, children: VecDeque<To>) -> Self
fn with_children_bi(&self, children: VecDeque<To>) -> Self
§fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
fn descend_bi(&self, op: &impl Fn(To) -> To) -> Self
Uniplate::descend] Read more§fn universe_bi(&self) -> VecDeque<To>
fn universe_bi(&self) -> VecDeque<To>
§fn children_bi(&self) -> VecDeque<To>
fn children_bi(&self) -> VecDeque<To>
§fn children_bi_count(&self) -> usize
fn children_bi_count(&self) -> usize
children_bi. Read more§fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
fn try_replace_child_at_bi(&mut self, index: usize, child: To) -> bool
§fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
fn transform_bi(&self, op: &impl Fn(To) -> To) -> Self
§fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn holes_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
§fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
fn contexts_bi(&self) -> impl Iterator<Item = (To, impl Fn(To))>
Source§impl CategoryOf for Expression
impl CategoryOf for Expression
Source§fn category_of(&self) -> Category
fn category_of(&self) -> Category
Category of a term.Source§impl Clone for Expression
impl Clone for Expression
Source§fn clone(&self) -> Expression
fn clone(&self) -> Expression
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for Expression
impl Debug for Expression
Source§impl<'de> Deserialize<'de> for Expression
impl<'de> Deserialize<'de> for Expression
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Display for Expression
impl Display for Expression
impl Eq for Expression
Source§impl From<AbstractLiteral<Expression>> for Expression
impl From<AbstractLiteral<Expression>> for Expression
Source§fn from(value: AbstractLiteral<Expression>) -> Self
fn from(value: AbstractLiteral<Expression>) -> Self
Source§impl From<Atom> for Expression
impl From<Atom> for Expression
Source§impl From<Literal> for Expression
impl From<Literal> for Expression
Source§impl From<Moo<Expression>> for Expression
impl From<Moo<Expression>> for Expression
Source§fn from(val: Moo<Expression>) -> Self
fn from(val: Moo<Expression>) -> Self
Source§impl From<Reference> for Expression
impl From<Reference> for Expression
Source§impl From<bool> for Expression
impl From<bool> for Expression
Source§impl From<i32> for Expression
impl From<i32> for Expression
Source§impl Hash for Expression
impl Hash for Expression
Source§impl MatrixValue for Expression
impl MatrixValue for Expression
Source§fn as_nested_matrix(&self) -> Option<&AbstractLiteral<Expr>>
fn as_nested_matrix(&self) -> Option<&AbstractLiteral<Expr>>
Source§fn into_nested_matrix(self) -> Result<AbstractLiteral<Expr>, Self>
fn into_nested_matrix(self) -> Result<AbstractLiteral<Expr>, Self>
Source§impl PartialEq for Expression
impl PartialEq for Expression
Source§impl Quine for Expression
impl Quine for Expression
fn ctor_tokens(&self) -> TokenStream
Source§impl Serialize for Expression
impl Serialize for Expression
impl StructuralPartialEq for Expression
Source§impl<'a> TryFrom<&'a Expression> for &'a Atom
impl<'a> TryFrom<&'a Expression> for &'a Atom
Source§impl TryFrom<&Expression> for ACOperatorKind
impl TryFrom<&Expression> for ACOperatorKind
Source§impl TryFrom<&Expression> for i32
impl TryFrom<&Expression> for i32
Source§impl TryFrom<Box<Expression>> for ACOperatorKind
impl TryFrom<Box<Expression>> for ACOperatorKind
Source§impl TryFrom<Expression> for ACOperatorKind
impl TryFrom<Expression> for ACOperatorKind
Source§impl TryFrom<Expression> for Atom
impl TryFrom<Expression> for Atom
Source§impl TryFrom<Expression> for i32
impl TryFrom<Expression> for i32
Source§impl TryFrom<IntVal> for Expression
impl TryFrom<IntVal> for Expression
Source§impl Typeable for Expression
impl Typeable for Expression
fn return_type(&self) -> ReturnType
Source§impl Uniplate for Expression
impl Uniplate for Expression
Source§fn uniplate(
&self,
) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Expression>)
fn uniplate( &self, ) -> (Tree<Expression>, Box<dyn Fn(Tree<Expression>) -> Expression>)
Uniplate. Read moreSource§fn try_replace_child_at(&mut self, index: usize, child: Expression) -> bool
fn try_replace_child_at(&mut self, index: usize, child: Expression) -> bool
§fn descend(&self, op: &impl Fn(Self) -> Self) -> Self
fn descend(&self, op: &impl Fn(Self) -> Self) -> Self
§fn universe(&self) -> VecDeque<Self>
fn universe(&self) -> VecDeque<Self>
§fn with_children(&self, children: VecDeque<Self>) -> Self
fn with_children(&self, children: VecDeque<Self>) -> Self
§fn transform(&self, f: &impl Fn(Self) -> Self) -> Self
fn transform(&self, f: &impl Fn(Self) -> Self) -> Self
§fn rewrite(&self, f: &impl Fn(Self) -> Option<Self>) -> Self
fn rewrite(&self, f: &impl Fn(Self) -> Option<Self>) -> Self
§fn cata<T>(&self, op: &impl Fn(Self, VecDeque<T>) -> T) -> T
fn cata<T>(&self, op: &impl Fn(Self, VecDeque<T>) -> T) -> T
Auto Trait Implementations§
impl !Freeze for Expression
impl !RefUnwindSafe for Expression
impl !UnwindSafe for Expression
impl Send for Expression
impl Sync for Expression
impl Unpin for Expression
impl UnsafeUnpin for Expression
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> 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> ⓘ
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> ⓘ
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 moreimpl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
§impl<T> WithSubscriber for T
impl<T> WithSubscriber for T
§fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘwhere
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘwhere
S: Into<Dispatch>,
§fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ
fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 144 bytes
Size for each variant:
AbstractLiteral: 119 bytesRoot: 111 bytesBubble: 103 bytesComprehension: 95 bytesDominanceRelation: 95 bytesFromSolution: 95 bytesMetavar: 95 bytesAtomic: 119 bytesTypeAnnotation: 103 bytesDomainAnnotation: 103 bytesActive: 127 bytesRecordField: 127 bytesUnsafeIndex: 119 bytesSafeIndex: 119 bytesUnsafeSlice: 119 bytesSafeSlice: 119 bytesInDomain: 103 bytesToInt: 95 bytesAbs: 95 bytesSum: 95 bytesProduct: 95 bytesMin: 95 bytesMax: 95 bytesNot: 95 bytesOr: 95 bytesAnd: 95 bytesImply: 103 bytesIff: 103 bytesUnion: 103 bytesIn: 103 bytesIntersect: 103 bytesDifference: 103 bytesSupset: 103 bytesSupsetEq: 103 bytesSubset: 103 bytesSubsetEq: 103 bytesEq: 103 bytesNeq: 103 bytesGeq: 103 bytesLeq: 103 bytesGt: 103 bytesLt: 103 bytesSubsequence: 103 bytesSubstring: 103 bytesCatchUndef: 103 bytesSafeDiv: 103 bytesUnsafeDiv: 103 bytesSafeMod: 103 bytesUnsafeMod: 103 bytesNeg: 95 bytesFactorial: 95 bytesDefined: 95 bytesRange: 95 bytesToSet: 95 bytesToMSet: 95 bytesToRelation: 95 bytesUnsafePow: 103 bytesSafePow: 103 bytesFlatten: 103 bytesAttributeAsConstraint: 111 bytesAllDiff: 95 bytesSmtDistinct: 95 bytesAllDifferentExcept: 103 bytesElementId: 103 bytesTable: 103 bytesNegativeTable: 103 bytesAtLeast: 111 bytesAtMost: 111 bytesGcc: 111 bytesGccWeak: 111 bytesMinus: 103 bytesApart: 103 bytesParticipants: 95 bytesParty: 103 bytesParts: 95 bytesTogether: 103 bytesFlatAbsEq: 103 bytesFlatAllDiff: 111 bytesFlatMinEq: 143 bytesFlatSumGeq: 143 bytesFlatSumLeq: 143 bytesFlatIneq: 111 bytesFlatWatchedLiteral: 143 bytesFlatWeightedSumLeq: 143 bytesFlatWeightedSumGeq: 143 bytesFlatMinusEq: 103 bytesFlatProductEq: 111 bytesMinionDivEqUndefZero: 111 bytesMinionModuloEqUndefZero: 111 bytesMinionPow: 111 bytesMinionReify: 127 bytesMinionReifyImply: 127 bytesMinionWInIntervalSet: 143 bytesMinionWInSet: 143 bytesMinionElementOne: 127 bytesAuxDeclaration: 119 bytesSATInt: 103 bytesPairwiseSum: 103 bytesPairwiseProduct: 103 bytesImage: 103 bytesImageSet: 103 bytesPreImage: 103 bytesInverse: 103 bytesPermInverse: 95 bytesCompose: 103 bytesRestrict: 103 bytesLexLt: 103 bytesLexLeq: 103 bytesLexGt: 103 bytesLexGeq: 103 bytesFlatLexLt: 135 bytesFlatLexLeq: 135 bytesRelationProj: 119 bytesCard: 95 bytes