A decoded WebAssembly module.
Returned by QuickBEAM.WASM.disasm/1. Contains the module's type
signatures, imports, exports, function bodies with decoded opcodes,
memories, tables, globals, data segments, and custom sections.
Functions
Each function is a %QuickBEAM.WASM.Function{} struct with decoded
opcodes in the same {offset, name, ...operands} tuple format used
by QuickBEAM.Bytecode:
%QuickBEAM.WASM.Function{
index: 0,
name: "add",
type_idx: 0,
params: [:i32, :i32],
results: [:i32],
locals: [],
opcodes: [
{0, :local_get, 0},
{2, :local_get, 1},
{4, :i32_add},
{5, :end}
]
}
Summary
Types
@type export_desc() :: map()
@type import_desc() :: map()
@type t() :: %QuickBEAM.WASM.Module{ custom_sections: [map()], data: [map()], elements: [map()], exports: [export_desc()], functions: [QuickBEAM.WASM.Function.t()], globals: [map()], imports: [import_desc()], memories: [map()], start: non_neg_integer() | nil, tables: [map()], tags: [map()], types: [map()], version: non_neg_integer() }