Skip to content
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(api) Avoid using a closure to declare host function #420

Merged
merged 2 commits into from
Nov 27, 2020

Conversation

Hywan
Copy link
Contributor

@Hywan Hywan commented Nov 27, 2020

Closures as host functions are going to be disabled for a moment in
Wasmer, see wasmerio/wasmer#1841. In the
wasmer Python package, we were passing a closure to
Function::new_with_env. In order to get a regular function, this
patch stores the previously captured varibles into the function
environment. The only concerned variable is result_types.

Closures as host functions are going to be disabled for a moment in
Wasmer, see wasmerio/wasmer#1841. In the
`wasmer` Python package, we were passing a closure to
`Function::new_with_env`. In order to get a regular function, this
patch stores the previously captured varibles into the function
environment. The only concerned variable is `result_types`.
@Hywan Hywan added 🎉 enhancement New feature or request 📦 component-extension About the Python extension written in Rust labels Nov 27, 2020
@Hywan Hywan requested a review from jubianchi November 27, 2020 08:53
@Hywan Hywan self-assigned this Nov 27, 2020
@Hywan Hywan changed the title feat(api) Avoid using a closure to declare host function. feat(api) Avoid using a closure to declare host function Nov 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📦 component-extension About the Python extension written in Rust 🎉 enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants