add missing wasm runtime function (#29)
laizy aochyi@126.com
Fri, 06 Jan 2023 00:49:21 +0800
1 files changed,
16 insertions(+),
0 deletions(-)
M
src/witness/witness_calculator.rs
→
src/witness/witness_calculator.rs
@@ -82,6 +82,8 @@ "logStartComponent" => runtime::log_component(store),
"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)?);@@ -328,6 +330,20 @@ }
// Circom 2.0 pub fn show_memory(store: &Store) -> Function { + #[allow(unused)] + fn func() {} + 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)