Lines Matching refs:error

21 static void exit_with_error(const char *message, wasmtime_error_t *error,
35 wasmtime_error_t *error = in check_call() local
37 if (error != NULL || trap != NULL) in check_call()
38 exit_with_error("failed to call function", error, trap); in check_call()
71 wasmtime_error_t *error = in check_ok() local
73 if (error != NULL || trap != NULL) in check_ok()
74 exit_with_error("failed to call function", error, trap); in check_ok()
92 wasmtime_error_t *error = in check_trap() local
94 if (error != NULL) in check_trap()
95 exit_with_error("failed to call function", error, NULL); in check_trap()
147 wasmtime_error_t *error = wasmtime_wat2wasm(wat.data, wat.size, &binary); in main() local
148 if (error != NULL) in main()
149 exit_with_error("failed to parse wat", error, NULL); in main()
155 error = in main()
157 if (error) in main()
158 exit_with_error("failed to compile module", error, NULL); in main()
165 error = wasmtime_instance_new(context, module, NULL, 0, &instance, &trap); in main()
166 if (error != NULL || trap != NULL) in main()
167 exit_with_error("failed to instantiate", error, trap); in main()
222 error = wasmtime_memory_grow(context, &memory, 1, &old_size); in main()
223 if (error != NULL) in main()
224 exit_with_error("failed to grow memory", error, trap); in main()
233 error = wasmtime_memory_grow(context, &memory, 1, &old_size); in main()
234 assert(error != NULL); in main()
235 wasmtime_error_delete(error); in main()
236 error = wasmtime_memory_grow(context, &memory, 0, &old_size); in main()
237 if (error != NULL) in main()
238 exit_with_error("failed to grow memory", error, trap); in main()
245 error = wasmtime_memory_new(context, memorytype, &memory2); in main()
246 if (error != NULL) in main()
247 exit_with_error("failed to create memory", error, trap); in main()
261 static void exit_with_error(const char *message, wasmtime_error_t *error, in exit_with_error() argument
265 if (error != NULL) { in exit_with_error()
266 wasmtime_error_message(error, &error_message); in exit_with_error()
267 wasmtime_error_delete(error); in exit_with_error()