mirror of
https://github.com/c-cube/sidekick.git
synced 2025-12-07 11:45:41 -05:00
this library provides an abstract interface for what a SMT solver provides, independently of the underlying implementation technology.
21 lines
687 B
OCaml
21 lines
687 B
OCaml
(** Result of solving for the current set of clauses *)
|
|
|
|
module Model = Sidekick_model
|
|
|
|
(** Result of calling "check" *)
|
|
type t =
|
|
| Sat of Model.t (** Satisfiable *)
|
|
| Unsat of {
|
|
unsat_core: unit -> Lit.t Iter.t;
|
|
(** Unsat core (subset of assumptions), or empty *)
|
|
unsat_step_id: unit -> Proof_trace.step_id option;
|
|
(** Proof step for the empty clause *)
|
|
} (** Unsatisfiable *)
|
|
| Unknown of Unknown.t
|
|
(** Unknown, obtained after a timeout, memory limit, etc. *)
|
|
|
|
let pp out (self : t) =
|
|
match self with
|
|
| Sat _ -> Fmt.string out "Sat"
|
|
| Unsat _ -> Fmt.string out "Unsat"
|
|
| Unknown u -> Fmt.fprintf out "Unknown(%a)" Unknown.pp u
|