wasmtest

package
v0.11.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 2, 2026 License: Apache-2.0 Imports: 1 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package wasmtest builds minimal WASM plugin modules for tests, so runtime limits can be exercised without a TinyGo toolchain.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Module

func Module(manifest string, growPages uint32) []byte

Module returns a WASM plugin whose gk_register reports manifest (JSON) and whose gk_call dispatches on the first byte of the function name:

  • "s…" (e.g. "spin") loops forever;
  • "g…" (e.g. "grow") grows memory by growPages and returns true, or false when the memory limit refuses;
  • anything else returns "ok".

Memory starts at one page and declares no maximum, so the runtime's memory limit applies. gk_malloc is a bump allocator; there is no gk_free.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL