cryptol-2.12.0: Cryptol: The Language of Cryptography
Copyright(c) 2013-2016 Galois Inc.
LicenseBSD3
Maintainercryptol@galois.com
Stabilityprovisional
Portabilityportable
Safe HaskellSafe
LanguageHaskell2010

Cryptol.TypeCheck.Solver.SMT

Description

 
Synopsis

Setup

data Solver Source #

An SMT solver packed with a logger for debugging.

data SolverConfig Source #

Instances

Instances details
Show SolverConfig Source # 
Instance details

Defined in Cryptol.TypeCheck.InferTypes

Generic SolverConfig Source # 
Instance details

Defined in Cryptol.TypeCheck.InferTypes

Associated Types

type Rep SolverConfig :: Type -> Type #

NFData SolverConfig Source # 
Instance details

Defined in Cryptol.TypeCheck.InferTypes

Methods

rnf :: SolverConfig -> () #

type Rep SolverConfig Source # 
Instance details

Defined in Cryptol.TypeCheck.InferTypes

type Rep SolverConfig = D1 ('MetaData "SolverConfig" "Cryptol.TypeCheck.InferTypes" "cryptol-2.12.0-1cEC2pVyc8sLwNRndAigau" 'False) (C1 ('MetaCons "SolverConfig" 'PrefixI 'True) ((S1 ('MetaSel ('Just "solverPath") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 FilePath) :*: S1 ('MetaSel ('Just "solverArgs") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [String])) :*: (S1 ('MetaSel ('Just "solverVerbose") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Int) :*: S1 ('MetaSel ('Just "solverPreludePath") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [FilePath]))))

withSolver :: IO () -> SolverConfig -> (Solver -> IO a) -> IO a Source #

Execute a computation with a fresh solver instance.

startSolver :: IO () -> SolverConfig -> IO Solver Source #

Start a fresh solver instance

stopSolver :: Solver -> IO () Source #

Shut down a solver instance

isNumeric :: Prop -> Bool Source #

Assumes no And

Debugging

debugBlock :: Solver -> String -> IO a -> IO a Source #

debugLog :: DebugLog t => Solver -> t -> IO () Source #

Proving stuff

proveImp :: Solver -> [Prop] -> [Goal] -> IO [Goal] Source #

Returns goals that were not proved

checkUnsolvable :: Solver -> [Goal] -> IO Bool Source #

Check if the given goals are known to be unsolvable.

tryGetModel :: Solver -> [TVar] -> [Prop] -> IO (Maybe [(TVar, Nat')]) Source #

shrinkModel :: Solver -> [TVar] -> [Prop] -> [(TVar, Nat')] -> IO [(TVar, Nat')] Source #