Draft / Experimental: Zith documentation describes a language under active development. Check Implementation Status before relying on a feature.
Implementation status:
stdlib/c/io.zithandstdlib/std/io/console.zithare the only shipped modules.putsandprintlnwork. All other standard library content is spec-only. See impl-status.md.
| Namespace | Stability | Use when |
|---|---|---|
std |
Stable, backward-compatible | You need a guaranteed API |
soon |
Experimental, may change | You're prototyping and don't mind breakage |
c |
Direct C FFI bindings | You need to call C APIs |
import std;
import soon; // use with caution — API may shift
import c; // raw C bindings
std/io/consolefn println(msg: []char): void;
fn print(msg: []char): void;
fn eprint(msg: []char): void;
@println("hello");
std/collections/DynArraystruct DynArray<T> {
fn push(self: lend, val: T);
fn pop(self): ?T;
fn len(self): u64;
fn get(self, index: u64): ?T;
}
std/fsstruct File { ... }
fn open(path: string): File!;
fn read(self: view File): []u8!;
fn write(self: lend File, data: []u8): void!;
| Trait | What it enables |
|---|---|
Copy |
Bitwise copy — primitives and components get this by default |
Clone |
fn clone(self): Self! |
Lent |
Can appear as a lend parameter |
Share |
Safe to share across threads |
Zith Language Specification — Draft v0.9