Standard Library
Current standard library module inventory, stability, public exports, and internal modules.
This is the current std module inventory. It lists module-level exports and
re-exports from lib/std/**/*.zx; methods on exported types are documented in
the module-specific pages linked from this section.
Stability labels:
mvp: normal source may import this module under the documented current contract.internal: implementation support for stdlib/compiler code, not a user API.experimental: reserved for future stdlib modules behind an explicit experimental boundary. No currentlib/stdmodule is experimental.
Removed modules:
std.task: removed from the source and SDK surface. Usestd.future.
The mvp label is a current-docs classification, not a released stability
badge. Zynx is still 0.0.0-dev, so even mvp modules may change before a
beta or tagged release.
Policy
Std stability labels, API naming policy, and composable primitive rules.
Core Modules
Builtins, memory helpers, allocator support, strings, bit operations, and arithmetic.
Data Structures
Collections, Array, HashMap, iterators, Iterable, hashing, encoding, JSON, cryptography, Unicode helpers, and lexical paths.
Runtime Surfaces
Environment access, sync IO, async IO, filesystem text read/write, OS bindings, sockets, channels, futures, and durations.
Module Inventory
Module status, public exports, error sets, and implementation notes.
The public async module is std.future.
Async calls return future.Future<T> values, and structured concurrency uses
future.all, future.race, future.timeout, and future.Group<T, E>.
std.task is not part of the current source or SDK surface.
| Module | Stability | Public Types | Public Functions, Values, And Re-exports | Public Errors | Notes |
|---|---|---|---|---|---|
std | mvp | none | copy, move, drop, iter | none | Auto-preluded root helper namespace. This does not auto-import std submodules. move and drop are compiler-recognized ownership operations; iter is the minimal slice/array iterator entry point. |
std.aio | mvp | Reader, Writer, Stream, DescriptorReader, DescriptorWriter, DescriptorStream | write, read, stdin, stdout, stderr | IOError | Async descriptor adapters. Descriptor wrappers borrow file descriptors and operations return Future values that throw IOError. |
std.allocator | mvp | Allocator | none | AllocError | Raw allocation interface. Allocation failures are reported as AllocError. |
std.arith | mvp | none | checked, overflowing, saturating, wrapping | none | Facade for explicit integer arithmetic policy modules. |
std.arith.checked | mvp | none | add, sub, mul | none | Checked integer helpers return nullable results instead of trapping. |
std.arith.overflowing | mvp | none | add, sub, mul | none | Helpers return result plus overflow flag. |
std.arith.saturating | mvp | none | add, sub, shl | none | Helpers clamp at numeric bounds. |
std.arith.wrapping | mvp | none | add, sub, mul | none | Helpers perform explicit wrapping arithmetic. |
std.bit | mvp | none | swap_bytes, reverse_bits, count_ones, leading_zeros, trailing_zeros, rotate_left, rotate_right | none | Integer bit operations. |
std.builtin | internal | Copy, Integer, Signed, Unsigned | none | DynamicError | Auto-imported compiler surface. Marker interfaces and DynamicError are language-reserved, not ordinary user-extensible APIs. |
std.bytes | mvp | Bytes | none | none | Non-owning byte views over strings, String, and byte slices. Text validation is not implicit. |
std.bytes.core | mvp | Bytes | none | none | Defines the Bytes view type re-exported by std.bytes. |
std.channel | mvp | Recv, Sender, Receiver | bounded | ChannelError | Bounded channels own buffered values. bounded is a runtime intrinsic, and cross-thread-capable sends require send-safe payloads. |
std.collections | mvp | Array, HashMap | none | none | Collection facade. Growing owned collections may throw AllocError through their methods. |
std.collections.array | mvp | ArrayIter, ArrayCopyIter, Array | none | none | Growable owned or borrowed array storage. Mutating growth operations may throw AllocError. |
std.collections.hash_map | mvp | HashBucket, HashMap | none | none | Hash map storage. HashBucket is an implementation-shaped exported layout type, not a construction helper. |
std.compress | mvp | none | deflate, gzip | none | Compression facade. Public algorithms return io.MemoryStream for allocating helpers. |
std.compress.deflate | mvp | Format | no_compression, best_speed, best_compression, default_compression, compress_bound, compress_into, decompress_into, compress, decompress | CompressError | Deflate and zlib helpers. Allocating helpers may also throw AllocError and io.IOError. |
std.compress.gzip | mvp | none | no_compression, best_speed, best_compression, default_compression, compress_bound, compress_into, decompress_into, compress, decompress | CompressError | Gzip helpers. Allocating helpers may also throw AllocError and io.IOError. |
std.compress.internal.zlib_ffi | internal | none | z_no_flush, z_finish, z_ok, z_stream_end, z_need_dict, z_stream_error, z_data_error, z_mem_error, z_buf_error, z_version_error, max_chunk, compress_bound, deflate_init, inflate_init, deflate_step, inflate_step, deflate_end, inflate_end, raise | CompressError | Internal zlib ABI shim for compression modules. Not a 0.0.0-dev user API. |
std.crypto | mvp | none | secure_zero, box, errors, hash, password, random, secretbox, sign | CryptoError | Crypto facade. Key-owning types zero secret storage on drop where implemented. |
std.crypto.box | mvp | PublicKey, SecretKey, Seed, Nonce, KeyPair | public_key_bytes, secret_key_bytes, seed_bytes, nonce_bytes, mac_bytes, seal_overhead, seal_into, open_into, seal, open | CryptoError | Public-key authenticated encryption. Allocating helpers may also throw AllocError. |
std.crypto.errors | mvp | none | none | CryptoError | Shared crypto error set. |
std.crypto.hash | mvp | none | blake2b | none | Hash facade. |
std.crypto.hash.blake2b | mvp | Digest, Key | bytes_min, bytes_max, bytes, key_bytes_min, key_bytes_max, key_bytes, sum_into, sum_keyed_into, sum, sum_keyed | CryptoError | BLAKE2b hashing. Keyed helpers use owned key material. |
std.crypto.internal.util | internal | none | status_ok, status_invalid, status_buffer, status_auth, status_random, status_resource, status_init, raise, secure_zero, alloc_bytes, copy_exact | none | Internal crypto support. Not a 0.0.0-dev user API. |
std.crypto.password | mvp | none | argon2id | none | Password-hashing facade. |
std.crypto.password.argon2id | mvp | Profile, Salt | salt_bytes, str_bytes, bytes_min, bytes_max, opslimit_interactive, memlimit_interactive, opslimit_moderate, memlimit_moderate, opslimit_sensitive, memlimit_sensitive, hash_password, verify, needs_rehash, derive_key_into | CryptoError | Argon2id password hashing and key derivation. Allocating helpers may also throw AllocError. |
std.crypto.random | mvp | none | fill, uint32, uniform | CryptoError | Cryptographic randomness. |
std.crypto.secretbox | mvp | Key, Nonce | key_bytes, nonce_bytes, mac_bytes, seal_overhead, seal_into, open_into, seal, open | CryptoError | Secret-key authenticated encryption. Allocating helpers may also throw AllocError. |
std.crypto.sign | mvp | none | ed25519 | none | Signature facade. |
std.crypto.sign.ed25519 | mvp | PublicKey, SecretKey, Seed, Signature, KeyPair | public_key_bytes, secret_key_bytes, seed_bytes, signature_bytes, sign_into, sign, verify | CryptoError | Ed25519 signatures. Allocating helpers may also throw AllocError. |
std.encoding | mvp | none | base64, base64url, hex | HexError | Text encoders and decoders over explicit byte views. |
std.encoding.base64 | mvp | none | encode, encode_no_pad | none | Base64 encoding returns UTF-8 String output. |
std.encoding.base64url | mvp | none | encode, encode_no_pad | none | URL-safe Base64 encoding returns UTF-8 String output. |
std.encoding.hex | mvp | none | encoded_length, decoded_length, valid, encode, encode_upper, encode_into, encode_upper_into, decode_into, decode | HexError | Hex encode/decode helpers. Allocating helpers may also throw AllocError. |
std.env | mvp | none | args, get | none | Process-environment helpers for CLI tools. The initial current development surface exposes borrowed process arguments and environment lookup. |
std.fs | mvp | none | read_file, write_file | none | Minimal filesystem convenience module. read_file reads validated String text; write_file creates or truncates a text file and writes the complete string. |
std.future | mvp | Future, Task, Group | ready, sleep, yield, readable, writable, all, race, timeout | AsyncError | Compiler-recognized cold-future surface. Structured operations include child errors plus AsyncError where cancellation or timeout is represented. |
std.hash | mvp | Hashable, Hasher | crc32, crc32c, fnv32a, fnv64a | none | Hash interfaces and algorithm facade. Interfaces are static-only constraints in the current language. |
std.hash.crc32 | mvp | Crc32 | sum | none | CRC-32 hasher and one-shot helper. |
std.hash.crc32c | mvp | Crc32c | sum | none | CRC-32C hasher and one-shot helper. |
std.hash.fnv32a | mvp | Fnv32a | none | none | FNV-1a 32-bit hasher. |
std.hash.fnv64a | mvp | Fnv64a | none | none | FNV-1a 64-bit hasher. |
std.io | mvp | Reader, Writer, Stream, DescriptorReader, DescriptorWriter, DescriptorStream, MemoryStream | print, println, eprint, eprintln, write, read, stdin, stdout, stderr | IOError | Synchronous byte I/O. Descriptor wrappers borrow descriptors. MemoryStream owns its backing buffer. CLI print helpers ignore low-level write status. |
std.iter | mvp | Iterable, Iterator, SliceIter, Iter | none | none | Minimal iterator facade for array/slice-backed pipelines. Current working adapters cover next, next_or, skip, take, fold, any, all, and count; broader lazy adapters remain TODO. |
std.iter.iterable | mvp | Iterable | none | none | Defines the static Iterable constraint re-exported by std.iter. |
std.json | mvp | Value, Token, Decoder, Encoder | decode, encode, null, boolean, string, number, array, object | JsonError | Strict JSON decode/encode, typed decode<T> for supported targets and @derive(json) structs, token input decoding, mutable DOM values, and streaming output. Numbers are exposed as validated source text. |
std.mem | mvp | none | copy, move, set, zero, compare, find, slice_of, owned_slice, is_owned, write_at, read_at, move_at, drop_at, str_from_raw, address_of, swap | none | Low-level memory helpers. Raw-pointer validity is the caller's responsibility and str_from_raw is unsafe. |
std.net | mvp | none | dns, ipaddr, socket, tcp, udp | NetError | Networking facade. DNS uses the host resolver and is not hermetic. |
std.net.dns | mvp | none | resolve | none | Async DNS resolution returning socket addresses. Uses io.IOError and AllocError. |
std.net.errors | mvp | none | raise, raise_last | NetError | Platform network-error mapping helpers. |
std.net.ipaddr | mvp | AddressFamily, Ipv4Addr, Ipv6Addr, IpAddr, SocketAddr | family_code, addr_family_code, addr_port, addr_v4, addr_v6_hi, addr_v6_lo, socket_addr_from_raw | none | Address parse/format values. The raw bridge helpers are exported for std.net submodules and are not the documented application API. |
std.net.socket | mvp | SocketKind, Socket | stream_kind_code, datagram_kind_code, local_addr_for, peer_addr_for, connect_fd, recv_ptr_fd, send_ptr_fd, write_fd, recv_from_fd, send_to_ptr_fd, bind_fd, bind_listen_fd, open_connected_fd, accept_fd | none | Low-level async socket layer. Raw bridge helpers are for std.net submodules; application code should use Socket methods and TCP/UDP wrappers. |
std.net.tcp | mvp | TcpListener, TcpStream | none | none | Owned TCP listener and stream wrappers. Stream I/O inherits std.io partial and EOF semantics. |
std.net.udp | mvp | UdpSocket | none | none | Owned UDP socket wrapper. Datagram boundaries are preserved and short buffers truncate datagrams. |
std.os | mvp | none | stdin, stdout, stderr, errno, exit, read, write, close, pipe, set_nonblocking, sync | none | Low-level OS descriptors and foreign C ABI calls. Prefer std.io or std.aio for normal I/O. |
std.path | mvp | none | basename, dirname, extension, join | none | Lexical Unix-style path helpers. No filesystem access or normalization beyond join boundary separator handling. |
std.string | mvp | String | none | none | Owned UTF-8 string. Construction from bytes validates text and growth may throw AllocError. |
std.time | mvp | Duration | ns, us, ms, sec, to_nanoseconds | TimeError | Duration construction with checked unit conversion. |
std.unicode | mvp | Decode | utf8, utf16le | UnicodeError | Unicode facade. Grapheme clusters and normalization are out of 0.0.0-dev. |
std.unicode.utf16le | mvp | none | valid, to_utf8_into, to_utf8 | UnicodeError | UTF-16LE validation and UTF-8 conversion. Allocating conversion may throw AllocError. |
std.unicode.utf8 | mvp | Decode | valid, count, decode, encode, to_utf16le_into, to_utf16le | UnicodeError | UTF-8 validation, decoding, encoding, and UTF-16LE conversion. Allocating conversion may throw AllocError. |