Stream: SIG-Packaging

Topic: wasm-pkg-tools and wit-parser


view this post on Zulip nikomatsakis (Nov 27 2024 at 10:23):

I'm trying to figure out how to connect the various pieces here. I'm working on an experimental programming language project that will integrate with WASM components. The idea is that I want people to be able to just write something like use wasi:cli/command and then seamlessly work with it.

To make this work I need to be able to go from a user-provided name like wasi:io/error/error to the definition it refers to, fetching any required dependencies etc along the way. I will have many such names to process in rather unreliable orders so I'd like to cache things. Basically the API I want to end up with is like

struct ComponentDependencies {}
impl ComponentDependencies {
    pub fn get(&mut self, package: &str, path: &str) -> Result<Definition>
}

As best I can tell the workflow should be something like

Some questions:

view this post on Zulip Lann Martin (Nov 27 2024 at 13:50):

I believe this is intended to be what you're looking for but I'm not sure exactly what state it is in right now: https://docs.rs/wasm-pkg-core/0.8.5/wasm_pkg_core/resolver/struct.DependencyResolver.html


Last updated: Dec 23 2024 at 12:05 UTC