Commit Graph

4 Commits

Author SHA1 Message Date
Peter Huene
42e88c7b24 Fix OutOfFuel trap code not represented in the C API. (#5230)
This commit adds the missing "out of fuel" trap code to the C API.

Without this, calls to `wasmtime_trap_code` will trigger an unreachable panic
on traps from running out of fuel.
2022-11-10 20:42:26 +00:00
TheGreatRambler
2ba3025e67 Add cmake compatibility to c-api (#4369)
* Add cmake compatibility to c-api

* Add CMake documentation to wasmtime.h

* Add CMake instructions in examples

* Modify CI for CMake support

* Use correct rust in CI

* Trigger build

* Refactor run-examples

* Reintroduce example_to_run in run-examples

* Replace run-examples crate with cmake

* Fix markdown formatting in examples readme

* Fix cmake test quotes

* Build rust wasm before cmake tests

* Pass CTEST_OUTPUT_ON_FAILURE

* Another cmake test

* Handle os differences in cmake test

* Fix bugs in memory and multimemory examples
2022-07-22 10:22:36 -07:00
Alex Crichton
7a1b7cdf92 Implement RFC 11: Redesigning Wasmtime's APIs (#2897)
Implement Wasmtime's new API as designed by RFC 11. This is quite a large commit which has had lots of discussion externally, so for more information it's best to read the RFC thread and the PR thread.
2021-06-03 09:10:53 -05:00
Ryan Brewster
2145855954 Add example of execution limits using fuel consumption (#2869)
* Add example of execution limits using fuel consumption

* run rustfmt

* Use a more naive WAT implementation

* Catch error and return cleanly

* Add a C example to demonstrate fuel consumption

* Add error handling for add_fuel
2021-05-04 10:39:01 -05:00