Mark McCaskey
3eff8c1973
Convert usages of Instance::{func,dyn_func}
to exports.get
2020-03-26 18:13:45 -07:00
Mark McCaskey
a18371eb91
Implement instance.exports
field syntax
2020-03-26 16:24:23 -07:00
Mark McCaskey
f4dc419b5e
Add types and methods to provide updated API
2020-03-17 15:27:11 -07:00
losfair
0f663887ad
Handle panics from DynamicFunc.
2020-03-16 22:49:37 +08:00
losfair
7d2d89b606
Resolve review comments.
2020-03-10 12:28:54 +08:00
Ivan Enderlin
4d3e8ee117
test(runtime-core) Test polymorphic host functions with more types.
2020-03-05 14:17:04 +01:00
losfair
31a72e59fb
Rename ErasedFunc to DynamicFunc and fix leaky PolymorphicContext
.
2020-02-28 11:41:36 +08:00
losfair
b67acbc0e3
Add ErasedFunc
for type-erased functions.
2020-02-25 01:19:19 +08:00
Ivan Enderlin
2ee1e80f3b
feat(runtime-core) Allow dynamic signature for polymorphic host functions.
...
This patch adds a new field in `Func`: `signature`. It contains the
signature of the host function.
For non-polymorphic host functions, the signature is computed from the
`Args` and `Rets` implementation parameters at compile-time.
For polymorphic host functions though, to be fully dynamic, the
signature given to `new_polymorphic` is used in `Func` as the correct
signature.
2020-02-17 15:50:12 +01:00
losfair
12373bb872
Func::new_polymorphic
2020-02-15 01:31:49 +08:00
Mark McCaskey
132645e0d0
Fix trap handling bug on Windows and add test
2020-02-11 13:24:26 -08:00
losfair
e0aafbe9dd
Remove WasmTrapInfo
and passExceptionCode
in the generic Box<Any>
container.
2020-02-06 23:49:50 +08:00
Ivan Enderlin
6f84a6f15b
test(runtime-core) Remove a warning in tests.
2019-11-06 14:48:47 +01:00
Ivan Enderlin
a9e0e9baeb
test(runtime-core) Write more documentation.
2019-11-06 14:48:46 +01:00
Ivan Enderlin
3435ce436b
test(runtime-core) Extract assert
as tests.
2019-11-06 14:48:46 +01:00
Ivan Enderlin
a52b4b2280
test(runtime-core) Test closures with a captured environment.
2019-11-06 14:48:46 +01:00
Ivan Enderlin
2a041f898e
!temp
2019-11-06 14:48:46 +01:00
Ivan Enderlin
0e27f2fa72
test(runtime-core) Test more host functions as closures.
2019-11-06 14:48:46 +01:00
Ivan Enderlin
7eef49be12
test(runtime-core) Test host functions without a vm::Ctx
argument.
2019-10-30 19:34:04 +01:00
Ivan Enderlin
bdc1ab3412
feat(runtime-core-tests) Introduce the new wasmer-runtime-core-tests
crate.
...
This non-publishable new crate contains a test suite for the
`wasmer-runtime-core` crate. So far, the test suite is rather small,
but it aims to be extended in a close future.
2019-10-30 13:28:01 +01:00