| Safe Haskell | None |
|---|---|
| Language | Haskell98 |
Language.SMTLib2.Internals.Monad
- newtype SMT b a = SMT {}
- data SMTState b = SMTState {}
- withBackend :: Backend b => SMTMonad b b -> SMT b a -> SMTMonad b a
- withBackendExitCleanly :: (Backend b, SMTMonad b ~ IO) => IO b -> SMT b a -> IO a
- liftSMT :: Backend b => SMTMonad b a -> SMT b a
- embedSMT :: Backend b => (b -> SMTMonad b (a, b)) -> SMT b a
- embedSMT' :: Backend b => (b -> SMTMonad b b) -> SMT b ()
- registerDatatype :: (Backend b, IsDatatype dt) => Datatype dt -> SMT b ()
- defineVar' :: Backend b => Expr b t -> SMT b (Var b t)
- defineVarNamed' :: Backend b => String -> Expr b t -> SMT b (Var b t)
- declareVar' :: Backend b => Repr t -> SMT b (Var b t)
- declareVarNamed' :: Backend b => Repr t -> String -> SMT b (Var b t)
Documentation
The SMT monad is used to perform communication with the SMT solver. The type of solver is given by the b parameter.
Instances
| Backend b => Monad (SMT b) Source # | |
| Backend b => Functor (SMT b) Source # | |
| Backend b => Applicative (SMT b) Source # | |
| (Backend b, MonadIO (SMTMonad b)) => MonadIO (SMT b) Source # | |
| Backend b => MonadState (SMTState b) (SMT b) Source # | |
| Backend b => Embed (SMT b) (Expr b) Source # | |
| type EmVar (SMT b) (Expr b) Source # | |
| type EmQVar (SMT b) (Expr b) Source # | |
| type EmFun (SMT b) (Expr b) Source # | |
| type EmFunArg (SMT b) (Expr b) Source # | |
| type EmLVar (SMT b) (Expr b) Source # | |
Arguments
| :: Backend b | |
| => SMTMonad b b | An action that creates a fresh backend. |
| -> SMT b a | The SMT action to perform. |
| -> SMTMonad b a |
Execute an SMT action on a given backend.
withBackendExitCleanly :: (Backend b, SMTMonad b ~ IO) => IO b -> SMT b a -> IO a Source #
Like withBackend but specialized to the IO monad so exeptions can be
handled by gracefully exiting the solver.
registerDatatype :: (Backend b, IsDatatype dt) => Datatype dt -> SMT b () Source #