mirror of
https://github.com/logos-storage/logos-storage-proofs.git
synced 2026-01-02 13:33:10 +00:00
update ffi
This commit is contained in:
parent
f850b6652c
commit
aa7750bc4b
@ -1,4 +1,4 @@
|
||||
|
||||
task genffi, "update the nim ffi bindings":
|
||||
exec "cargo install --force nbindgen"
|
||||
exec "cargo install nbindgen"
|
||||
exec "nbindgen --crate codex-storage-proofs --output codex_proofs_ffi.nim"
|
||||
|
||||
@ -26,9 +26,9 @@ proc free_prover*(prover: ptr StorageProofs) {.importc: "free_prover".}
|
||||
## # Safety
|
||||
#
|
||||
# Construct a StorageProofs object
|
||||
proc init_proof_ctx*(r1cs: Buffer,
|
||||
wasm: Buffer,
|
||||
zkey: ptr Buffer): (ptr StorageProofs) {.importc: "init_proof_ctx".}
|
||||
proc init_storage_proofs*(r1cs: Buffer,
|
||||
wasm: Buffer,
|
||||
zkey: ptr Buffer): (ptr StorageProofs) {.importc: "init_storage_proofs".}
|
||||
|
||||
## # Safety
|
||||
#
|
||||
|
||||
@ -25,4 +25,4 @@ import codex_proofs_ffi
|
||||
export codex_proofs_ffi
|
||||
|
||||
when isMainModule:
|
||||
init()
|
||||
init_proof_ctx()
|
||||
|
||||
@ -36,7 +36,7 @@ impl ProofCtx {
|
||||
///
|
||||
/// Construct a StorageProofs object
|
||||
#[no_mangle]
|
||||
pub unsafe extern "C" fn init_proof_ctx(
|
||||
pub unsafe extern "C" fn init_storage_proofs(
|
||||
r1cs: Buffer,
|
||||
wasm: Buffer,
|
||||
zkey: *const Buffer,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user