| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
Data.SBV.Program.Utils
Synopsis
- sampleSpec :: forall a comp spec. (SymVal a, SynthSpec spec a) => spec a -> IO (Maybe (IOs a))
- isConstantComponent :: forall a comp spec. (SynthSpec spec a, SynthComponent comp spec a) => comp a -> Bool
- mkVarName :: String -> Bool -> Bool -> Word -> String
- mkInputLocName :: String -> Word -> String
- mkOutputLocName :: String -> String
- mkInputVarName :: String -> Word -> String
- mkOutputVarName :: String -> String
- writePseudocode :: (Show a, SynthComponent comp spec a) => Program Location (comp a) -> String
Documentation
sampleSpec :: forall a comp spec. (SymVal a, SynthSpec spec a) => spec a -> IO (Maybe (IOs a)) Source #
Given a SynthSpec tries to generate a set of input/output values that satisfy the specification.
Uses solver under the hood.
isConstantComponent :: forall a comp spec. (SynthSpec spec a, SynthComponent comp spec a) => comp a -> Bool Source #
Arguments
| :: String | Base name, which can be an empty string, in which case "UnnamedComponent" value will be used. |
| -> Bool | Setting |
| -> Bool | If |
| -> Word | Number of an input. Can be |
| -> String |
Creates sanitized variable name suitable for SBV.
mkInputLocName :: String -> Word -> String Source #
Shortcut for the more general mkVarName function.
mkInputVarName :: String -> Word -> String Source #
Shortcut for the more general mkVarName function.
writePseudocode :: (Show a, SynthComponent comp spec a) => Program Location (comp a) -> String Source #
Renders the solution in SSA style.