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.
@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
none of this is written down, we just wanted to leave it reserved for the module-types proposal
Dan also rightly pointed out that having everything as *.wat
kinda makes more sense since it's all wasm text anyway
none of this is really set in stone though to be clear
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
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.
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
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.
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.
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