Lines Matching refs:error

19 static void exit_with_error(const char *message, wasmtime_error_t *error,
36 wasmtime_error_t *error; in main() local
39 error = wasmtime_module_new(engine, (uint8_t *)linking1_wasm.data, in main()
41 if (error != NULL) in main()
42 exit_with_error("failed to compile linking1", error, NULL); in main()
43 error = wasmtime_module_new(engine, (uint8_t *)linking2_wasm.data, in main()
45 if (error != NULL) in main()
46 exit_with_error("failed to compile linking2", error, NULL); in main()
59 error = wasmtime_context_set_wasi(context, wasi_config); in main()
60 if (error != NULL) in main()
66 error = wasmtime_linker_define_wasi(linker); in main()
67 if (error != NULL) in main()
68 exit_with_error("failed to link wasi", error, NULL); in main()
72 error = wasmtime_linker_instantiate(linker, context, linking2_module, in main()
74 if (error != NULL || trap != NULL) in main()
75 exit_with_error("failed to instantiate linking2", error, trap); in main()
78 error = wasmtime_linker_define_instance(linker, context, "linking2", in main()
80 if (error != NULL) in main()
81 exit_with_error("failed to link linking2", error, NULL); in main()
85 error = wasmtime_linker_instantiate(linker, context, linking1_module, in main()
87 if (error != NULL || trap != NULL) in main()
88 exit_with_error("failed to instantiate linking1", error, trap); in main()
95 error = wasmtime_func_call(context, &run.of.func, NULL, 0, NULL, 0, &trap); in main()
96 if (error != NULL || trap != NULL) in main()
97 exit_with_error("failed to call run", error, trap); in main()
127 wasmtime_error_t *error = wasmtime_wat2wasm(wat.data, wat.size, bytes); in read_wat_file() local
128 if (error != NULL) in read_wat_file()
129 exit_with_error("failed to parse wat", error, NULL); in read_wat_file()
133 static void exit_with_error(const char *message, wasmtime_error_t *error, in exit_with_error() argument
137 if (error != NULL) { in exit_with_error()
138 wasmtime_error_message(error, &error_message); in exit_with_error()
139 wasmtime_error_delete(error); in exit_with_error()