cryptol-3.0.0: Cryptol: The Language of Cryptography
Safe HaskellSafe-Inferred
LanguageHaskell2010

Cryptol.Eval.FFI

Description

Evaluation of foreign functions.

Synopsis

Documentation

findForeignDecls :: ModuleG mname -> [(Name, FFIFunType)] Source #

Find all the foreign declarations in the module and return their names and FFIFunTypes.

evalForeignDecls :: ForeignSrc -> [(Name, FFIFunType)] -> EvalEnv -> Eval (Either [FFILoadError] EvalEnv) Source #

Add the given foreign declarations to the environment, loading their implementations from the given ForeignSrc. This is a separate pass from the main evaluation functions in Cryptol.Eval since it only works for the Concrete backend.