feat(sat): provide a proof_dumm module

This commit is contained in:
Simon Cruanes 2021-12-07 14:08:16 -05:00
parent 9517e88467
commit cfede762c9
No known key found for this signature in database
GPG key ID: EBFFF6F283F3A2B4
3 changed files with 34 additions and 0 deletions

22
src/sat/Proof_dummy.ml Normal file
View file

@ -0,0 +1,22 @@
module Make(Lit : sig type t end)
: Solver_intf.PROOF
with type lit = Lit.t
and type t = unit
and type proof_step = unit
= struct
type lit = Lit.t
type t = unit
type proof_step = unit
type proof_rule = t -> proof_step
module Step_vec = Vec_unit
let enabled (_pr:t) = false
let del_clause _ _ (_pr:t) = ()
let emit_redundant_clause _ ~hyps:_ _ = ()
let emit_input_clause _ _ = ()
let emit_unsat _ _ = ()
let emit_unsat_core _ (_pr:t) = ()
end

9
src/sat/Proof_dummy.mli Normal file
View file

@ -0,0 +1,9 @@
(** Dummy proof module that does nothing. *)
module Make(Lit : sig type t end) : sig
include Solver_intf.PROOF
with type lit = Lit.t
and type t = unit
and type proof_step = unit
end

View file

@ -32,3 +32,6 @@ exception No_proof = Solver_intf.No_proof
module Solver = Solver
module Make_cdcl_t = Solver.Make_cdcl_t
module Make_pure_sat = Solver.Make_pure_sat
(** Module for dummy proofs based on unit *)
module Proof_dummy = Proof_dummy