Stream: general

Topic: status of .wit extension


view this post on Zulip Darin Morrison (Apr 08 2020 at 17:11):

Is it currently intended that the .wit extension will not be used for anything? I notice that in the commit (https://github.com/bytecodealliance/wasm-interface-types/commit/8c4cc5ee2e41d0ea06c7f3760eaa348378a46d51) a bunch of test files in the wasm-interface-types repo were renamed from *.wit to *.wat. I couldn't find a discussion around why the change was made though. The only other documentation I see that currently mentions .wit is this (https://github.com/WebAssembly/module-types/blob/master/proposals/module-types/Overview.md). Just wondering the status because I'm currently working on some parser tooling for webassembly text formats.

Don't try to co-opt the `*.wit` extension by accident.
Proposal for adding module types and their text format - WebAssembly/module-types

view this post on Zulip Alex Crichton (Apr 08 2020 at 17:15):

@Darin Morrison oh the *.wit extension is intended to be the "wasm interface type" file which is sort like a header file of sorts for wasm files, just containing the interface as opposed to the interface and the code

view this post on Zulip Alex Crichton (Apr 08 2020 at 17:15):

none of this is written down, we just wanted to leave it reserved for the module-types proposal

view this post on Zulip Alex Crichton (Apr 08 2020 at 17:15):

Dan also rightly pointed out that having everything as *.wat kinda makes more sense since it's all wasm text anyway

view this post on Zulip Alex Crichton (Apr 08 2020 at 17:17):

none of this is really set in stone though to be clear

view this post on Zulip Dan Gohman (Apr 08 2020 at 17:20):

Yeah; the current plan, extrapolated from that sentence at the bottom of module-types' Overview.md, is that "wit" is for both instances and modules, and just declares imports and exports

view this post on Zulip Darin Morrison (Apr 08 2020 at 17:21):

Okay, that clarifies the situation a bit, thanks. I'm guessing there aren't really examples of *.wit being used for module-types in the wild at this point? I couldn't find anything from a quick search.

view this post on Zulip Dan Gohman (Apr 08 2020 at 17:21):

while "wat" is defined in the wasm spec to be the textual counterpart to the binary "wasm" format, though it may include annotations such as @interface

view this post on Zulip Dan Gohman (Apr 08 2020 at 17:22):

Right, I don't know of anyone using "wit" right now. As I understand it, "wit" is more just a name for a particular point of interest in the design space.

view this post on Zulip Dan Gohman (Apr 08 2020 at 17:23):

In WASI, we're using "witx", which is "wit" plus some extensions useful for humans maintaining interface descriptions. We benefit from "wit" being a known concept that we can define hopefully modest extensions to, rather than being an entirely new thing.

view this post on Zulip Darin Morrison (Apr 08 2020 at 17:30):

Okay, cool. Good to know. I saw some of those .witx files in the wasi repo but wasn't sure about the relationship there.


Last updated: Nov 22 2024 at 16:03 UTC