mirror of
https://github.com/c-cube/sidekick.git
synced 2025-12-06 03:05:31 -05:00
feat(proof): do not emit trivial clause_rw steps
if there is no rewriting going on, we can skip the step.
This commit is contained in:
parent
aad1daa4e4
commit
e9b395b643
1 changed files with 10 additions and 5 deletions
|
|
@ -217,11 +217,16 @@ let lemma_cc lits (self:t) =
|
||||||
PS.(Step_view.Step_cc {Step_cc.eqns=lits})
|
PS.(Step_view.Step_cc {Step_cc.eqns=lits})
|
||||||
|
|
||||||
let lemma_rw_clause c ~res ~using (self:t) =
|
let lemma_rw_clause c ~res ~using (self:t) =
|
||||||
emit_ self @@ fun() ->
|
if enabled self then (
|
||||||
let lits = Iter.map (emit_lit_ self) res |> Iter.to_array in
|
let using = Iter.to_array using in
|
||||||
let res = Proof_ser.{Clause.lits} in
|
if Array.length using=0 then c (* useless step *)
|
||||||
let using = Iter.to_array using in
|
else (
|
||||||
PS.(Step_view.Step_clause_rw {Step_clause_rw.c; res; using})
|
emit_ self @@ fun() ->
|
||||||
|
let lits = Iter.map (emit_lit_ self) res |> Iter.to_array in
|
||||||
|
let res = Proof_ser.{Clause.lits} in
|
||||||
|
PS.(Step_view.Step_clause_rw {Step_clause_rw.c; res; using})
|
||||||
|
)
|
||||||
|
) else dummy_step
|
||||||
|
|
||||||
(* TODO *)
|
(* TODO *)
|
||||||
let with_defs _ _ (_pr:t) = dummy_step
|
let with_defs _ _ (_pr:t) = dummy_step
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue