WebAssembly / WebAssembly/component-model

WIT should have the same expressivity power as the component model

Open
#614 4 comments 5 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

My mental model has been that WIT is "just" syntax sugar[^0] on top of the component model: anything expressible in a raw component model interface should also be expressible in WIT.

[^0]: Curly brackets instead of S-expressions, stuff that helps bindings generators but don't affect semantics like doc comments, a package system to spread definitions across files, etc...

But this is not actually the case today. I strongly believe it should be.

The biggest counterexample I am aware of is https://github.com/WebAssembly/component-model/issues/287.

My hopes in filing this issue are two-fold:

  1. Build consensus that "anything expressible in a raw component model interface should also be expressible in WIT" is a highly-desirable property. Does anyone disagree? Can we formalize this into one of the design docs in this repo or something?

  2. We can do a collective survey/audit of CM features and exhaustively enumerate WIT's expressivity gaps. Is anyone aware of any other counterexamples?

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 counterexample in WebAssembly/component-model#287, then review the repository's design documents and the component model features they describe. Done means reaching consensus on whether WIT should match raw component-model expressivity, formalizing that property, and enumerating the remaining WIT expressivity gaps.

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
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.