From 874134f3ff726d969fd901fee18c1aceb415c03b Mon Sep 17 00:00:00 2001 From: Ernesto Lanchares Date: Sun, 23 Mar 2025 18:20:38 +0000 Subject: PROPOSAL: IR This is a proposal of a custom IR to run wasm. At the moment only `ir.zig` has some parts related to this IR. The idea of the IR is to be a subset of the one defined in wasm. There are some gaps (mostly in wasm instructions that have opcode 0xFC) but in wasm they don't use all of the opcodes for some reason so maybe we could try to utilize them and be a superset of wasm. --- src/mods/Parser.zig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mods/Parser.zig') diff --git a/src/mods/Parser.zig b/src/mods/Parser.zig index 29f18d8..d9f7ccf 100644 --- a/src/mods/Parser.zig +++ b/src/mods/Parser.zig @@ -144,7 +144,7 @@ fn parseReftype(self: *Parser) !std.wasm.RefType { // NOTE: Parsing of Valtype can be improved but it makes it less close to spec so... // TODO: Do we really need Valtype? -const Valtype = union(enum) { +pub const Valtype = union(enum) { val: std.wasm.Valtype, ref: std.wasm.RefType, }; -- cgit v1.2.3