A programming language for people who want to know what their code is doing.
Statically typed. Explicitly designed. No magic.
use std.runtime;
use print: std.print;
fun fib(n: i64) i64 {
if (n < 2) { ret n; }
ret fib(n - 1) + fib(n - 2);
}
$main.symbol = "main";
fun main(argc: i64, argv: **u8) i64 {
print.printf("hello, mach\n");
print.printf("fib(10) = %d\n", fib(10));
ret 0;
}
Mach is built on the belief that clarity is more valuable than cleverness, and that long-term maintainability outweighs short-term convenience.
The compiler, build system, test runner, and dependency manager are a single binary with no external dependencies. No LLVM. No libc. Just mach.
No garbage collector. Allocator types give you structured control over memory with arena and heap strategies. Scope-based cleanup via fin prevents leaks without runtime overhead.
The runtime, entry point, syscalls, and every allocation are ordinary Mach code you can open and read. The standard library is written in the same language you write — nothing is privileged, nothing is implicit. The program does exactly what its source says.
Query type sizes, alignments, and field offsets at compile time. Conditional compilation lets you write platform-specific code that is fully excluded from the binary when not targeted.
Generic types and functions are fully specialized at compile time. Zero runtime cost, no vtables, no type erasure. You get the code you wrote, and nothing else.
Build, test, and manage dependencies from a single command. The toolchain handles project scaffolding, dependency resolution, and test discovery out of the box.
Mach's backend is designed to be modular and target-independent. New platforms are added without modifying the core compiler.
x86_64
x86_64 / ARM64
x86_64
Download the latest release binary, then put it on your PATH.
chmod +x mach
sudo mv mach /usr/local/bin/
mach init my-app
cd my-app
mach build .
mach run .