mirror of
https://github.com/arnaucube/circom-compat.git
synced 2026-01-09 15:31:31 +01:00
add missing wasm runtime function (#29)
This commit is contained in:
@@ -82,6 +82,8 @@ impl WitnessCalculator {
|
||||
"log" => runtime::log_component(store),
|
||||
"exceptionHandler" => runtime::exception_handler(store),
|
||||
"showSharedRWMemory" => runtime::show_memory(store),
|
||||
"printErrorMessage" => runtime::print_error_message(store),
|
||||
"writeBufferMessage" => runtime::write_buffer_message(store),
|
||||
}
|
||||
};
|
||||
let instance = Wasm::new(Instance::new(&module, &import_object)?);
|
||||
@@ -333,6 +335,20 @@ mod runtime {
|
||||
Function::new_native(store, func)
|
||||
}
|
||||
|
||||
// Circom 2.0
|
||||
pub fn print_error_message(store: &Store) -> Function {
|
||||
#[allow(unused)]
|
||||
fn func() {}
|
||||
Function::new_native(store, func)
|
||||
}
|
||||
|
||||
// Circom 2.0
|
||||
pub fn write_buffer_message(store: &Store) -> Function {
|
||||
#[allow(unused)]
|
||||
fn func() {}
|
||||
Function::new_native(store, func)
|
||||
}
|
||||
|
||||
pub fn log_signal(store: &Store) -> Function {
|
||||
#[allow(unused)]
|
||||
fn func(a: i32, b: i32) {}
|
||||
|
||||
Reference in New Issue
Block a user