[][src]Crate walrus

The walrus WebAssembly transformations library.

Re-exports

pub use crate::ir::Local;
pub use crate::ir::LocalId;

Modules

dot

Utilities for emitting GraphViz dot files.

ir

Intermediate representation for expressions.

passes

Passes over whole modules or individual functions.

Structs

BlockBuilder

A builder returned by block-construction methods to build up block expressions over time.

CustomSection

A representation of a custom section in a module

Data

A passive data segment

Element

A passive segment which contains a list of functions

Export

A named item exported from the wasm.

Function

A wasm function.

FunctionBuilder

A helpful struct used for building instances of LocalFunction

FunctionTable

Components of a table of functions (anyfunc table)

Global

A wasm global.

Import

A named item imported into the wasm.

LocalFunction

A function defined locally within the wasm module.

Memory

A memory in the wasm.

MemoryData

An abstraction for the initialization values of a Memory.

Module

A wasm module.

ModuleConfig

Configuration for a Module which currently affects parsing.

ModuleData

All passive data sections of a wasm module, used to initialize memories via various instructions.

ModuleElements

All element segments of a wasm module, used to initialize anyfunc tables, used as function pointers.

ModuleExports

The set of exports in a module.

ModuleFunctions

The set of functions within a module.

ModuleGlobals

The set of globals in each function in this module.

ModuleImports

The set of imports in a module.

ModuleLocals

The set of locals in each function in this module.

ModuleMemories

The set of memories in this module.

ModuleProducers

Representation of the wasm custom section producers

ModuleTables

The set of tables in this module.

ModuleTypes

The set of de-duplicated types within a module.

Table

A table in the wasm.

Type

A function type.

Enums

ErrorKind

A leaf wasm error type.

ExportItem

An exported item.

FunctionKind

The local- or external-specific bits of a function.

GlobalKind

The different kinds of globals a wasm module can have

ImportKind

An imported item.

InitExpr

A constant which is produced in WebAssembly, typically used in global initializers or element/data offsets.

TableKind

The kinds of tables that can exist

ValType

A value type.

Type Definitions

DataId

A passive element segment identifier

ElementId

A passive element segment identifier

ExportId

The id of an export.

FunctionId

A function identifier.

GlobalId

The id of a global.

ImportId

The id of an import.

MemoryId

The id of a memory.

Result

Either Ok(T) or Err(failure::Error).

TableId

The id of a table.

TypeId

An identifier for types.