Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidMemoryIndex = fmt.Errorf("invalid memory index")
ErrInvalidMemoryIndex indicates that the memory index associated with a data section is not valid.
Functions ¶
func CompileCommand ¶
CompileCommand compiles the given WASI module into Go source code and writes the source to the given writer. The source will be contained in package main, and will contain a main function.
func CompileModule ¶
func CompileModule(w io.Writer, packageName, name string, module *wasm.Module, options *Options) error
CompileModule compiles the given module into Go source code and writes the source to the given writer. The source will be contained in the named package, and will contain an exec.ModuleDefintion with the exported version of the given name.
Types ¶
type Options ¶
type Options struct { // UseRawPointers enables the use of raw pointers in place of calls to exec.Memory methods for // loads and stores. UseRawPointers bool // NoInternalThreads disables the use of *exec.Thread inside the generated code. NoInternalThreads bool }
Options records compilation options.
Click to show internal directories.
Click to hide internal directories.