Errors as values
No exceptions, no hidden control flow. A function that can fail returns a union and you handle it with match.
Teko is a small, all-native systems language. Errors are values, memory is arena-based with no garbage collector, and the compiler is written in Teko — rebuilding itself to a byte-identical fixpoint.
// hello.tks — the Teko way to say hi
fn greet(name: str) -> str {
$"Hello, {name}!"
}
// main.tks — the entry is a linear virtual main
teko::io::println(greet("Guri"))
No exceptions, no hidden control flow. A function that can fail returns a union and you handle it with match.
Region-based automatic memory. Allocations belong to a lexical scope and are freed when it ends — deterministic, no collector, no pauses.
The compiler is written in Teko and rebuilds itself to a byte-identical binary. The build is its own proof of correctness.
Its own instruction selection, register allocation, object emission and static linker — targeting x86-64, arm64, riscv64 and wasm.
Unit tests live beside the code in .tkt files. Coverage floors are declared in the manifest and gate every build.
Link libc and system libraries and call C directly through extern — no wrapper layer, no runtime glue.
Teko compiles projects, not lone files — a project is a .tkp manifest plus a src/ directory. Four steps take you from install to output.
Grab the teko binary for your platform and put it on your PATH.
$ teko --version # → teko 0.3.0.21-betateko init lays down the manifest and a source directory with a starter module.
$ teko init hello && cd helloCode lives in src/*.tks. The entry point is a linear virtual main — top-level statements, run in order.
src/main.tks · teko::io::println("olá, Guri")One toolchain does everything — no external compiler or linker required.
$ teko run . # build (debug) + execute $ teko build . # native binary → bin/ $ teko test . # run .tkt tests + coverageNew to the language? The source is the best reference — the whole compiler is written in Teko. Browse it on GitHub ↗.
Teko ships as a single self-contained executable — no runtime to install, no dependencies beyond libc. Pick your platform on the Downloads page, then:
Get the archive for your OS and architecture, then extract the teko binary.
$ tar -xzf teko-0.3.0.21-beta-linux-x86_64.tar.gzMove it somewhere on your PATH (or add its folder).
$ install -m 0755 teko /usr/local/bin/tekoConfirm the toolchain is live.
$ teko --version # teko 0.3.0.21-betaPlatforms: Linux (x86-64, arm64), macOS (Apple silicon), Windows (x86-64). riscv64 and WASI are landing with the native-backend wave. On macOS, the download strips the quarantine attribute so the binary runs unsigned.
Teko is in active beta — every merge to the trunk cuts a versioned seed. Grab the latest prebuilt binary below, or build from source.
| Platform | Architecture | Version | |
|---|---|---|---|
| Linux | x86_64 · glibc | 0.3.0.21-beta | Download ↓ |
| Linux | arm64 · glibc | 0.3.0.21-beta | Download ↓ |
| macOS | arm64 · Apple silicon | 0.3.0.21-beta | Download ↓ |
| Windows | x86_64 | 0.3.0.21-beta | Download ↓ |
Prefer to build it yourself? Clone the repo and run the bootstrap — the compiler rebuilds itself from source. Direct mirror downloads at s3.teko-lang.cloud are being set up; for now releases live on GitHub ↗.