Safe Haskell | None |
---|---|
Language | Haskell98 |
This module contains an SMTLIB2 interface for 1. checking the validity, and, 2. computing satisfying assignments for formulas. By implementing a binary interface over the SMTLIB2 format defined at http://www.smt-lib.org/ http://www.grammatech.com/resource/smt/SMTLIBTutorial.pdf
- data Command
- data Response
- class SMTLIB2 a where
- data Context = Ctx {}
- makeContext :: Bool -> SMTSolver -> FilePath -> IO Context
- makeContextNoLog :: Bool -> SMTSolver -> IO Context
- makeContextWithSEnv :: Bool -> SMTSolver -> FilePath -> SMTEnv -> IO Context
- cleanupContext :: Context -> IO ExitCode
- command :: Context -> Command -> IO Response
- smtWrite :: Context -> Text -> IO ()
- smtDecl :: Context -> Symbol -> Sort -> IO ()
- smtAssert :: Context -> Expr -> IO ()
- smtCheckUnsat :: Context -> IO Bool
- smtCheckSat :: Context -> Expr -> IO Bool
- smtBracket :: Context -> IO a -> IO a
- smtDistinct :: Context -> [Expr] -> IO ()
- checkValid :: Bool -> FilePath -> [(Symbol, Sort)] -> Expr -> Expr -> IO Bool
- checkValidWithContext :: Context -> [(Symbol, Sort)] -> Expr -> Expr -> IO Bool
- checkValids :: Bool -> FilePath -> [(Symbol, Sort)] -> [Expr] -> IO [Bool]
- makeZ3Context :: FilePath -> [(Symbol, Sort)] -> IO Context
Commands
Commands issued to SMT engine
Responses
Responses received from SMT engine
Typeclass for SMTLIB2 conversion
Types that can be serialized
Creating and killing SMTLIB2 Process
Information about the external SMT process
makeContext :: Bool -> SMTSolver -> FilePath -> IO Context Source
SMT Context ---------------------------------------------------------
cleanupContext :: Context -> IO ExitCode Source
Execute Queries
command :: Context -> Command -> IO Response Source
SMT IO --------------------------------------------------------------
Query API
smtCheckUnsat :: Context -> IO Bool Source
smtBracket :: Context -> IO a -> IO a Source
smtDistinct :: Context -> [Expr] -> IO () Source
Theory Symbols
Check Validity
checkValid :: Bool -> FilePath -> [(Symbol, Sort)] -> Expr -> Expr -> IO Bool Source
type ClosedPred E = {v:Pred | subset (vars v) (keys E) } checkValid :: e:Env -> ClosedPred e -> ClosedPred e -> IO Bool