Stevia could profit by implementing or at least providing Nand, Nor and Xnor in addition to And, Or and Xor that currently exist. This could make some simplifications involving negation simpler or at least more performant temporarily.
These additional expression types could be implemented on several different layers.
Factory-layer: Only provided by the expression build interface that internally directly forwards to And, Or and Xor. The downside is that this is quite intransparent to users that might be confused why no actual negated versions are created.
In the expression AST. The advantage is that it is transparent, the downside is that it is a lot of repetition and requires another set of simplification rules for them. They could be simply directly reduced to their non-negated counterparts upon simplification without other simplifications occuring.
Stevia could profit by implementing or at least providing
Nand
,Nor
andXnor
in addition toAnd
,Or
andXor
that currently exist. This could make some simplifications involving negation simpler or at least more performant temporarily.These additional expression types could be implemented on several different layers.
And
,Or
andXor
. The downside is that this is quite intransparent to users that might be confused why no actual negated versions are created.