Runtime for Clojure code generated from Lean IR.
Functions named lean_* implement the C symbols of Lean's @[extern]
declarations, so generated code calls leanfran.runtime/<C symbol>.
Value representation:
Nat / Int: Long, or clojure.lang.BigInt when it does not fitUInt8..UInt32, Char, Bool, enumerations: LongUInt64 / USize: Long holding the 64-bit patternFloat: DoubleString: java.lang.String (positions are UTF-8 byte offsets)Array: persistent vectorLong (the constructor index)CtorClosureRuntime for Clojure code generated from Lean IR. Functions named `lean_*` implement the C symbols of Lean's `@[extern]` declarations, so generated code calls `leanfran.runtime/<C symbol>`. Value representation: - `Nat` / `Int`: `Long`, or `clojure.lang.BigInt` when it does not fit - `UInt8`..`UInt32`, `Char`, `Bool`, enumerations: `Long` - `UInt64` / `USize`: `Long` holding the 64-bit pattern - `Float`: `Double` - `String`: `java.lang.String` (positions are UTF-8 byte offsets) - `Array`: persistent vector - nullary constructors: `Long` (the constructor index) - other constructors: `Ctor` - closures: `Closure`
Whether a Lean panic throws an exception with ::panic data instead of
printing its message and returning the default value, as in a specification
that leanfran.typed/check runs.
Whether a Lean panic throws an exception with `::panic` data instead of printing its message and returning the default value, as in a specification that `leanfran.typed/check` runs.
(clj-chars? d v)Whether every Char of the Lean value v is a Clojure character.
Whether every `Char` of the Lean value `v` is a Clojure character.
(clj-function ns name)The var name of the namespace ns, as clj-var.
The var `name` of the namespace `ns`, as `clj-var`.
(clj-var ns name)The var name of the namespace ns, which the first call outside the load of
a namespace loads. Nil when the namespace is not loaded, or when the var has no
value yet.
The var `name` of the namespace `ns`, which the first call outside the load of a namespace loads. Nil when the namespace is not loaded, or when the var has no value yet.
(lean_byte_array_copy_slice src src-off dest dest-off len _exact)(registered-types)The structures and enumerations generated code has registered, by full Lean name.
The structures and enumerations generated code has registered, by full Lean name.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |