alexcrichton opened PR #4215 from component-vmcomponent
to main
:
This commit fills out the
wasmtime-runtime
crate's support for
VMComponentContext
and creates it as part of the instantiation
process. This moves a few maps that were temporarily allocated in an
InstanceData
into theVMComponentContext
and additionally reads the
canonical options data from there instead.This type still won't be used in its "full glory" until the lowering of
host functions is completely implemented, however, which will be coming
in a future commit.<!--
Please ensure that the following steps are all taken care of before submitting
the PR.
[ ] This has been discussed in issue #..., or if not, please tell us why
here.[ ] A short description of what this does, why it is needed; if the
description becomes long, the matter should probably be discussed in an issue
first.[ ] This PR contains test cases, if meaningful.
- [ ] A reviewer from the core maintainer team has been assigned for this PR.
If you don't know who could review this, please indicate so. The list of
suggested reviewers on the right can help you.Please ensure all communication adheres to the code of conduct.
-->
alexcrichton requested fitzgen for a review on PR #4215.
fitzgen submitted PR review.
fitzgen submitted PR review.
fitzgen created PR review comment:
This isn't technically safe right? Since the
ComponentInstance
is logically pinned, giving out an&mut
would allow moving it out bystd::mem::replace
ing it.
alexcrichton updated PR #4215 from component-vmcomponent
to main
.
alexcrichton submitted PR review.
alexcrichton created PR review comment:
That's a great point actually and something I totally missed! I removed this, made it a private internal accessor, and reexported
&mut
self methods from the un-owned version to the owned version.
alexcrichton updated PR #4215 from component-vmcomponent
to main
.
alexcrichton merged PR #4215.
Last updated: Nov 22 2024 at 16:03 UTC