Small bugfixes in the component macros #829
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
These are the changes required for hyperlight-wasm-http-example to build and run correctly.
I think that we need better test coverage for the macro, and I believe @syntactically is working on that.
However, I would like to get these changes in for the 0.9.0 release.
The change in
resolve_tv
, in the case of aTypeBound::SubResource
the function was returning a relative index instead of an absolute index. In the other non-recursive branch,TypeBound::Eq
, we need to return the relative index. I believe @syntactically is also working on a more sane refactor of this method.The change in the generated code, when the host sends some resource to the guest, it needs to insert them in the resource table, for that the code in
#marshal
assumes that a variablerts
is in scope, which was not the case. Also,rts
is behind a mutex that we need to release before doing the actual guest function call, so creation ofargs
is moved forward.