|
|
@ -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) {}
|
|
|
|