lean-bindings-0.1: Haskell bindings to the Lean Theorem Prover.

Copyright(c) Galois Inc, 2015
LicenseApache-2
Maintainerjhendrix@galois.com, lcasburn@galois.com
Safe HaskellTrustworthy
LanguageHaskell98

Language.Lean.Internal.Expr

Contents

Description

Internal declarations for Lean expressions and typeclass instances for Expr.

Synopsis

Macro definitions

type MacroDefPtr = Ptr MacroDef Source

Haskell type for lean_macro_def FFI parameters.

type OutMacroDefPtr = Ptr MacroDefPtr Source

Haskell type for lean_macro_def* FFI parameters.

withMacroDef :: MacroDef -> (Ptr MacroDef -> IO a) -> IO a Source

Function c2hs uses to pass MacroDef values to Lean

Expressions

data Expr Source

A Lean expression

type ExprPtr = Ptr Expr Source

Haskell type for lean_expr FFI parameters.

type OutExprPtr = Ptr ExprPtr Source

Haskell type for lean_expr* FFI parameters.

withExpr :: Expr -> (Ptr Expr -> IO a) -> IO a Source

Get access to lean_expr within IO action.

exprLt :: Expr -> Expr -> Bool Source

Return true if first expression is structurally less than other.

exprToString :: Expr -> String Source

Return the string representation of an expression.

List of expressions

type ListExpr = List Expr Source

Synonym for List Expr that can be used in c2hs bindings

type ListExprPtr = Ptr ListExpr Source

Haskell type for lean_list_expr FFI parameters.

type OutListExprPtr = Ptr ListExprPtr Source

Haskell type for lean_list_expr* FFI parameters.

withListExpr :: List Expr -> (Ptr (List Expr) -> IO a) -> IO a Source

Function c2hs uses to pass ListExpr values to Lean