Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Support index

The reference describes the supported subset, not Python’s full API. Detailed restrictions live with their contracts.

AreaContract and principal limits
Source and modulesDeclarations, imports, visibility, and entrypoints; compile-time constant expressions, static assertions, and included files; if const target conditionals over a closed set of target facts; one source root per package, no import cycles or re-exports
Packagesplenty.toml, path and Git dependencies pinned in plenty.lock, version requirements, workspaces, plenty add/fetch/update, per-target build reuse, optimized/fast-compile profiles, plenty test with per-process test functions run in parallel under optional timeouts, and plentyc --package-graph; no registry or version selection
Types and dataTypes, including byte literals of type bytes; fixed layouts and recursive data through heap boundaries; read-only std.bytes operations and stream writes take a &[u8] view of bytes, Bytes or list[u8] without copying
ExpressionsOperators, assignment, and control flow; blocks and expressions nest to 64 levels; f-strings with any expression as a field and compile-time Python format specs, whose nested fields supply only fill, alignment, width, and precision; copying slices xs[a:b:c]? of lists, text, bytes, tuples, and clists; local slice views &xs[a:b] of lists and bytes, typed &[T], and of text, typed &substr, with &xs, &s, and literals converting to the whole view where a view is expected; no slice assignment
OwnershipMoves, checked borrows, returned references including Option[&T] and Result[&T, E], and cleanup; general stored references unsupported
FunctionsNamed functions and concrete closures; named arguments and fresh per-call defaults for static calls, with callable/builtin/protocol restrictions; explicit fallible shared-call erasure
GenericsConcrete specialization and structural protocols, including integer/bool value parameters and Bounded, and requirements with their own protocol-constrained type parameters; methods of a generic class or enum instance are checked and compiled only when used; explicit boxed protocol dispatch with shared/mutable receivers
DimensionsCompile-time dimensions: nominal bases, normalized algebra, exact roots and Dimension generic arguments; Quantity construction, numeric/domain operators, conversions, coherent-unit formatting, module constants and scoped alias diagnostic notes. Storage-type native ABI with release instruction evidence
Errors and resourcesSums, propagation, allocation, and context scopes; traps do not unwind; explicit std.error result mapping and contexts
IterationLoops, comprehensions, and native generators; local serial pipelines with borrowed sources, fused adapters including chain, flat_map, and callback-free filter_value, reductions, next(p), lending as &mut Iter[T], and parallel pipelines on a pool with .par(&pool) over owned or borrowed lists and ranges; no reference yield or public borrow across suspension
Built-insNumeric, text, and collection operations; explicitly fallible allocating operations; columnar lists for primitive-field classes with borrowed scalar pipelines
Standard libraryEmbedded std.math, std.path, std.fs, std.deque, and std.bytes; typed errors, Linux paths/metadata and walking, owned double-ended queues, and compact byte buffers. std.time adds checked durations, monotonic deadlines, and wall timestamps. std.io adds partial-progress byte streams, retry helpers, and fixed-capacity buffering over files, process streams, and memory. std.encoding adds strict hex/base64 codecs and explicit-endian integer packing. std.url adds strict RFC 3986 URL parsing, component-aware percent encoding, and query pairs. std.collections adds binary heaps. std.complex adds f64 complex numbers with arithmetic operators. std.cache.lru adds fixed-capacity least-recently-used caches. std.csv adds bounded streaming CSV records and writers. std.random adds caller-owned seeded generators and std.secrets OS-backed secret bytes and tokens. std.crypto adds digests, HMAC, BLAKE3 hashing/key derivation, constant-time comparison, and AEAD, Ed25519, X25519, and HKDF. std.compress adds bounded gzip, zlib, and DEFLATE streams. std.archive adds TAR and ZIP reading, writing, and confined extraction. std.regex adds linear-time regular expressions with explicit resource limits. std.db.sqlite adds SQLite databases through typed prepared statements and owned transactions. std.json adds strict, bounded JSON: a resumable event decoder, a validating encoder, and a value tree. std.log adds leveled structured events with explicit, bounded sinks. std.toml adds strict, bounded TOML 1.0 parsing and writing over a value tree. std.env reads variables and the working directory, and std.process spawns owned children from argument vectors without a shell, with pipes, bounded output collection, signals, and explicit reaping. std.ready adds readiness waits on one handle or many (selectors) under a deadline and a cancellation token that wakes them directly. std.actor runs supervised actors over std.ready on x86-64 and AArch64 GNU/Linux, each with a limited heap that a trap discards, bounded mailboxes of copied messages, timers, request-reply and opt-in restart. std.signal delivers SIGTERM and SIGINT as an event, so a server can drain when its supervisor stops it. std.net adds TCP and UDP sockets, IP address parsing, and cancellable name lookup under the same deadlines. std.tls adds verified TLS client and server streams over those sockets, with client certificates, ALPN, SNI certificate selection, revocation lists, and selector-driven use. std.http adds bounded HTTP/1.1 message framing with streamed bodies and strict rejection of ambiguous framing. std.http.server serves it, and HTTPS through std.tls, with typed routes, bounded workers and admission, idle connections parked on a selector, per-phase deadlines, and graceful shutdown; its qualification lists the production gates it passes. std.http.client sends requests over pooled connections with deadlines, bounded redirects, an explicit proxy, and streamed uploads, shares one pool between threads through Shared, and std.http.https adds verified https with CONNECT tunnels. std.http.body, std.http.cookie and std.http.proxy add bounded forms, JSON and multipart uploads, validated cookies, and trusted-proxy client addresses for handlers. std.http.files serves static files confined to a root directory; cookies can be signed. std.test adds assertions that report their caller’s position, fixtures, fake clocks and streams, and allocation and file failure injection for plenty test. std.diff adds Myers and patience differences over lists, bytes, and text tokens, with unified-diff output
I/OText/byte streams, raw Unix paths, and owned UTF-8 files; direct file iteration unsupported
ConcurrencyThreads, channels, pools, futures, and parallel operations, with atomics and mutexes shared through scoped-thread borrows or atomically counted Shared[T] owners; certified worker effects, serial ordinary loops; no weak handles
InteroperabilityTrusted C imports, exports, metadata, and runtime loading
Editor supportLanguage server with diagnostics, hover, go to definition, and completion, configured for Neovim; generic bodies resolve per instantiation
Native toolchainCommands and artifacts, and per-function IR and assembly dumps; native x86_64-unknown-linux-gnu and aarch64-unknown-linux-gnu, linking with the matching host cc; release requirements and ARM qualification distinguish implementation from tested deployment environments

The ARM path uses generic ARMv8-A instructions, scalar std.simd, Linux ELF, and the AAPCS64 C ABI. It is a release platform: the release workflow builds the compiler and both optional engines in the glibc 2.28 image on native ARM runners, runs the full suite there, and smoke-tests the archives in AlmaLinux 8 and Debian 13. Kernels older than the one tested, page sizes other than 4 KiB and other distributions are not tested; see the ARM development notes. x86-64 retains its SSE2 baseline. Selecting --target or a linker does not turn an installed compiler into a cross-compiler.

Native emission for aarch64-apple-darwin and x86_64-pc-windows-msvc is experimental. It includes target ABI, Mach-O/COFF objects and native linker invocation. Release packaging includes the dataframe dylib on macOS ARM64 and the dataframe DLL on Windows x86-64, with their metadata and notices. The linear algebra engine remains Linux-only. Native release/portability workflows check Parquet queries and application distributions after relocation. Native CI and the release workflow pass compiler/runtime builds and unit tests, platform-boundary checks, and compilation and execution of a generated callback/result program on both operating systems. Runtime and standard-library capabilities remain incomplete, including actor recovery and several OS services, and these checks do not establish standard-library parity; see experimental macOS and Windows downloads.

There is no interpreter, REPL, JIT, async/await, inheritance, dynamic attributes, or exception unwinding. Future work and priorities remain in the backlog.