Comments (5)
I just updated my project to use the new extend
. Very nice, seems to be working great. 🎉
from wasmer.
@lachlansneff What would you think about representing imports object during instantiation with something like the following?
Vec<(String, String, &Export)>
or a struct instead of a tuple. I used &Export
here so that the user code can own the export (not move it) and we can clone it during instantiation.
If there were duplicate module/name
pairs that would result in an error.
from wasmer.
I want to apologize for my somewhat curt issue description. I was just a bit disappointed that my PR was not going to get merged. But I don't have the same insight into the project, so it's very understandable if there's another solution in mind. (It's your project after all. 😁)
To illustrate the functionality I'm looking for, it might help to show my usage:
https://github.com/tprk77/experiments_in_ros2_rust_and_wasm
Specifically, these lines:
I have two versions of the same "app," one in Rust and one in C++. I want to expose the same API imports to both. But to get the C++ app working, I also need the Emscripten imports. (ros::get_imports()
is returning an ImportObject
containing a ROS2-like API.)
The actual mechanism doesn't really matter to me, but it would be nice if I could still use the imports!
macro because it's so convenient. My concern at the moment is with Emscripten, but I think there's also a more general issue of what to do when there are multiple import objects corresponding to multiple APIs. For example, if the mod sensors
supplies an import object for a Sensor API, while the mod motors
supplies an import object for the Motors API, how to we use both in the same instance?
from wasmer.
@tprk77, we're really sorry about not being responsive enough with your other issue. Things have been quite busy here. I'll make sure to take a look at this pr tomorrow morning.
from wasmer.
That's great! We're glad to hear that.
Thanks for your PR by the way, it helped me get adjusted to the Wasmer code base! Best of luck with your project and let us know if there's anything we can do for you to make using Wasmer better!
from wasmer.
Related Issues (20)
- CLI: "container unpack" command does not correctly unpack atoms HOT 1
- Mobile compatible wasmer engine HOT 4
- example wasm.hh Code running error HOT 1
- Upgrade to tlsv2 HOT 2
- Fuzz tests are broken HOT 1
- WASI Preview 2 Support HOT 3
- Fetching logs for an app fails HOT 2
- Broken on nightly because of ahash 0.7 (aka "update hashbrown") HOT 4
- PHP execution breaks after consecutive requests HOT 2
- Fix failure when fetching logs for an app HOT 2
- Make wordpress (in PHP) run end to end in Wasmer/WASIX HOT 2
- Potential Bug: Use-of-Uninitialized-Value HOT 1
- Possible race condition on `virtual-fs` HOT 1
- CI: Run tests with nightly rustc HOT 1
- Build PHP locally HOT 2
- Add README for wasi-fyi tests HOT 1
- CLI: "wasmer deploy" auto package version bump does not work if package version is out of date HOT 1
- Deprecation of `cfg_attr(..., crate_type = "...")` HOT 2
- (WASI) Wrong file offset after file write in append mode HOT 1
- fs::readdir performance in wasi is not great HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wasmer.