smtlib2-0.2: A type-safe interface to communicate with an SMT solver.

Safe HaskellNone
LanguageHaskell98

Language.SMTLib2.Internals.Instances

Description

Implements various instance declarations for SMTType, SMTValue, etc.

Synopsis

Documentation

valueToHaskell :: DataTypeInfo -> (forall t. SMTType t => [ProxyArg] -> t -> SMTAnnotation t -> r) -> Maybe Sort -> Value -> r Source

extractAnnotation :: SMTExpr a -> SMTAnnotation a Source

Reconstruct the type annotation for a given SMT expression.

entype :: (forall a. SMTType a => SMTExpr a -> b) -> SMTExpr Untyped -> b Source

entypeValue :: (forall a. SMTValue a => SMTExpr a -> b) -> SMTExpr UntypedValue -> b Source

undefArg :: b a -> a Source

Get an undefined value of the type argument of a type.

withSort :: DataTypeInfo -> Sort -> (forall t. SMTType t => t -> SMTAnnotation t -> r) -> r Source

withNumSort :: DataTypeInfo -> Sort -> (forall t. (SMTType t, Num t) => t -> SMTAnnotation t -> r) -> Maybe r Source

withSorts :: DataTypeInfo -> [Sort] -> (forall arg. Liftable arg => arg -> ArgAnnotation arg -> r) -> r Source

withArraySort :: DataTypeInfo -> [Sort] -> Sort -> (forall i v. (Liftable i, SMTType v) => SMTArray i v -> (ArgAnnotation i, SMTAnnotation v) -> a) -> a Source

foldExprM :: (SMTType a, Monad m) => (forall t. SMTType t => s -> SMTExpr t -> m (s, [SMTExpr t])) -> s -> SMTExpr a -> m (s, [SMTExpr a]) Source

Recursively fold a monadic function over all sub-expressions of this expression

foldArgsM :: (Args a, Monad m) => (forall t. SMTType t => s -> SMTExpr t -> m (s, [SMTExpr t])) -> s -> a -> m (s, [a]) Source

Recursively fold a monadic function over all sub-expressions of the argument

foldExpr :: SMTType a => (forall t. SMTType t => s -> SMTExpr t -> (s, SMTExpr t)) -> s -> SMTExpr a -> (s, SMTExpr a) Source

Recursively fold a function over all sub-expressions of this expression. It is implemented as a special case of foldExprM.

foldExprMux :: SMTType a => (forall t. SMTType t => s -> SMTExpr t -> (s, [SMTExpr t])) -> s -> SMTExpr a -> (s, [SMTExpr a]) Source

foldArgs :: Args a => (forall t. SMTType t => s -> SMTExpr t -> (s, SMTExpr t)) -> s -> a -> (s, a) Source

Recursively fold a function over all sub-expressions of the argument. It is implemented as a special case of foldArgsM.

foldArgsMux :: Args a => (forall t. SMTType t => s -> SMTExpr t -> (s, [SMTExpr t])) -> s -> a -> (s, [a]) Source

compareFun :: (Args a1, Args a2) => SMTFunction a1 r1 -> SMTFunction a2 r2 -> Ordering Source

compareField :: Field a1 f1 -> Field a2 f2 -> Ordering Source

compareArgs :: (Args a1, Args a2) => a1 -> a2 -> Ordering Source

valueToConst :: DataTypeInfo -> Value -> (forall a. SMTType a => [ProxyArg] -> a -> SMTAnnotation a -> b) -> b Source