gizlang:capability
The kernel and library capabilities this process has, probed when asked. A name is available when its probe succeeds. require is the startup check: a configured capability that is missing, or a name that is not known, fails it with the name in the message, and nothing falls back. CPU features are in gizlang:machine (Machine.has).
import * as Capability from "gizlang:capability";Types
Capability
type Capability = { name: string; available: bool; }A capability and whether this process has it.
name:stringavailable:bool
Functions
available
function available(sys: System, name: string): boolWhether capability NAME is available: io_uring when a ring can be made, zstd and brotli when their library opens. False for a name this module does not know.
Effects: fail, io.
capabilities
function capabilities(sys: System): Vec<Capability>Every known capability and whether this process has it.
Effects: fail, io.
require
function require(sys: System, names: Vec<string>): bool throws stringThe startup check: every configured name must be a known capability (in knownNames) and available. The first name that is unknown or missing fails it.
Effects: fail, io.