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.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(runtime-c-api) Implement
wasmer_trap
#1133feat(runtime-c-api) Implement
wasmer_trap
#1133Changes from 13 commits
ec37859
e913e89
35459c2
6846204
c7a4825
4bf3d6d
8790f6d
b45ead2
a506411
b494bd8
6e7d5ba
b5e96b8
176152e
c0b439e
4cdf868
bcbde69
cd16a7d
ce3fb49
f4ae606
fb06ee3
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps we should panic here? Seems like a small thing, not sure what best practice is here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cbindgen doesn't generate a C bindgen for a Rust function with
!
as returned type.Since I need to error before calling
do_early_trap
, I've decided to return awasmer_result_t
. And in the best scenario, I returnWASMER_OK
, even if it's unreachable. I'll add more documentation to explain.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I prefer
returned
toreturning
here;, we return a trampoline...
is probably best though.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought it was an English typo.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe it's grammatically correct and called the "passive voice", it's often discouraged in English though because it takes more words and ends up being less specific. For example, I generally prefer direct writing like, "This function takes a function signature and returns a corresponding trampoline".