Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- startRuntime :: Bool -> RuntimeHost -> Text -> IO (Runtime Symbol)
- withRuntime :: MonadUnliftIO m => Bool -> RuntimeHost -> Text -> (Runtime Symbol -> m a) -> m a
- startNativeRuntime :: Text -> FilePath -> IO (Runtime Symbol)
- standalone :: CCache -> Word64 -> IO StoredCache
- runStandalone :: Bool -> StoredCache -> CombIx -> IO (Either (Pretty ColorText) ())
- data StoredCache = SCache (EnumMap Word64 Combs) (EnumMap Word64 Reference) (EnumSet Word64) (EnumMap Word64 Reference) Word64 Word64 (Map Reference (SuperGroup Symbol)) (Map Reference Word64) (Map Reference Word64) (Map Reference (Set Reference))
- decodeStandalone :: ByteString -> Either String (Text, Text, CombIx, StoredCache)
- data RuntimeHost
- = OneOff
- | Persistent
- data Runtime v = Runtime {
- terminate :: IO ()
- evaluate :: CodeLookup v IO () -> PrettyPrintEnv -> Term v -> IO (Either Error ([Error], Term v))
- compileTo :: CompileOpts -> CodeLookup v IO () -> PrettyPrintEnv -> Reference -> FilePath -> IO (Maybe Error)
- mainType :: Type v Ann
- ioTestTypes :: NESet (Type v Ann)
- getStoredCache :: MonadGet m => m StoredCache
- putStoredCache :: MonadPut m => StoredCache -> m ()
Documentation
startRuntime :: Bool -> RuntimeHost -> Text -> IO (Runtime Symbol) Source #
withRuntime :: MonadUnliftIO m => Bool -> RuntimeHost -> Text -> (Runtime Symbol -> m a) -> m a Source #
standalone :: CCache -> Word64 -> IO StoredCache Source #
runStandalone :: Bool -> StoredCache -> CombIx -> IO (Either (Pretty ColorText) ()) Source #
data StoredCache Source #
A version of the Code Cache designed to be serialized to disk as standalone bytecode.
SCache (EnumMap Word64 Combs) (EnumMap Word64 Reference) (EnumSet Word64) (EnumMap Word64 Reference) Word64 Word64 (Map Reference (SuperGroup Symbol)) (Map Reference Word64) (Map Reference Word64) (Map Reference (Set Reference)) |
Instances
Show StoredCache Source # | |
Defined in Unison.Runtime.Interface showsPrec :: Int -> StoredCache -> ShowS # show :: StoredCache -> String # showList :: [StoredCache] -> ShowS # | |
Eq StoredCache Source # | |
Defined in Unison.Runtime.Interface (==) :: StoredCache -> StoredCache -> Bool # (/=) :: StoredCache -> StoredCache -> Bool # |
decodeStandalone :: ByteString -> Either String (Text, Text, CombIx, StoredCache) Source #
data RuntimeHost Source #
Whether the runtime is hosted within a persistent session or as a one-off process. This affects the amount of clean-up and book-keeping the runtime does.
Runtime | |
|
Exported for tests
getStoredCache :: MonadGet m => m StoredCache Source #
putStoredCache :: MonadPut m => StoredCache -> m () Source #