Stream: git-wasmtime

Topic: wasmtime / PR #4236 Split the `ComponentValue` trait into...


view this post on Zulip Wasmtime GitHub notifications bot (Jun 07 2022 at 14:44):

alexcrichton opened PR #4236 from lift-lower-split to main:

This commit splits the current ComponentValue trait into three
separate traits:

When describing the original implementation of host functions to Nick he
immediately pointed out this superior solution to the traits involved
with Wasmtime's support for typed parameters/returns in exported and
imported functions. Instead of having dynamic errors at runtime for
things like "you can't lift a String" that's instead a static
compile-time error now.

While I was doing this split I also refactored the ComponentParams
trait a bit to have ComponentType as a supertrait instead of a subtype
which made its implementations a bit more compact. Additionally its impl
blocks were folded into the existing tuple impl blocks.

<!--

Please ensure that the following steps are all taken care of before submitting
the PR.

Please ensure all communication adheres to the code of conduct.
-->

view this post on Zulip Wasmtime GitHub notifications bot (Jun 07 2022 at 14:44):

alexcrichton requested fitzgen for a review on PR #4236.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 07 2022 at 16:53):

fitzgen submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 07 2022 at 17:29):

alexcrichton merged PR #4236.


Last updated: Nov 22 2024 at 17:03 UTC