Module Satproc


module Satproc: sig .. end
This defines the signature that a satisfiability procedure must implement

module E: Errormsg
module I: Input
module L: Logic

This defines the signature that a satisfiability procedure must implement
exception Contradiction of Proof.proof

a proof of False
exception Proved of Proof.proof

a proof of the current goal assumption
type ident = string 
The unique identifier of a satisfiability procedure

type message = {
   body : Logic.pred; (*The predicate being asserted. This is most often an atom, but it might be the left-hand side of an implication, when that is not a conjunction.*)
   owner : ident; (*Who is responsible for producing a proof of this*)
   id : int; (*The responsible satisf. proc can use this to later identify the message*)
   goal : bool; (*If it is a goal. In this case the asserted predicate is the negation of "body"*)
   aboutToFail : bool; (*If this flag is set in a message, it means that, unless there is a contradiction for this message, we are going to fail the proof. The sat. procedures can use more expensive mechanisms if this is the case*)
}
type entries = {
   init : unit -> unit; (*Record a snapshot*)
   snapshot : unit -> unit; (*Discard all assertions since last not-undone snapshot*)
   undo : unit -> unit; (*Assert a literal (the second argument). Accumulate the list of equalities to the first argument. Might raise Contradiction, or (if the assertion is a goal) Proved*)
   assume : message list -> message -> message list; (*Prove a message generated earlier.*)
   proveIt : message -> Proof.proof;
   debug : bool Pervasives.ref;
   ident : ident; (*The identifier*)
   descr : string; (*A short description*)
}
There are the entry points in a decision procedure

There is a global pointer to a procedure for proof generation. satisfiability procedures can call this when they need to produce a proof for a message belonging to some _OTHER_ satproc.
val proveIt : (message -> Proof.proof) Pervasives.ref
val d_message : unit -> message -> Pretty.doc
Pretty print a message
module type SATPROC = sig .. end

type parserSpec = {
   language : string; (*The name of the language. This is used to construct a command line option --langinput*)
   initParser : string -> Lexing.lexbuf -> unit; (*Initialization*)
   nextFewInputs : Lexing.lexbuf -> Input.input list;
}
A specification for a parser