WebAssembly / WebAssembly/component-model

More options for deriving worlds

Open
#563 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
WebAssembly
Stars
1.4k
Forks
130
Avg merge
2d 1h
Merged PRs (30d)
15

Description

Currently one can use include to derive one world from another, however I've been finding myself wanting more ways:

  • include_imports - Like include, but only includes imports
  • include_exports - Like include, but only includes exports
  • include_imports_exported - Like include_imports except translates the imports to exports
  • include_exports_imported - Like include_exports except translates the exports to imports

(suggestions for better syntax/naming welcome)

For example, include_imports would be useful when one wants to make a library component that can link to another component and otherwise occupy the same world. And include_imports_exported would be useful when one wants to make a world for the implementation that components of another world need.

In my current projects, I'm finding myself effectively working around the lack of include_imports by splitting out worlds that only have imports and than having the main worlds and library worlds include them. And for the lack of include_imports_exported I'm manually duplicating and translating imports in one world to exports in another.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the issue's description of the existing include world derivation and the four proposed variants. Review the component model's current world, import, and export semantics, then determine the syntax and behavior for each form. Done means the proposal resolves naming and design questions and specifies all four derivation modes consistently.

Written by the indexing model from the issue text.

Assessment

Tech stack
wasm
Domain
compilers
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.