final class CompletionReduction

Eliminates independent subtrees using exact empty/non-empty costs instead of enumerating their derivations.

Methods§

public function __construct(
    private CompletionCosts $costs,
    private ConstraintDependencies $dependencies,
)

Independent subtrees cannot consume any remaining pattern counter and therefore commute with the constrained walk.

Parameters

public function reduce(
    CompletionState $state,
    GenerationPlan<bool> $plan,
    CompletionFrontier $frontier,
): bool

Private surface 2§

Implementation details, listed for orientation only.

private CompletionCosts $costs
private ConstraintDependencies $dependencies

Test cases 23§

Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.

Dedicated tests 1
Other tests reaching this symbol 22

Relations§

Instantiated in 1
Method calls 1
Type declarations 1