Zag — blazing fast. super clean.

Zag is a systems language focused on clean, expressive syntax without giving up explicit control, predictable performance, or native compilation. It compiles to Zig, letting the Zig toolchain handle code generation, linking, and cross-compilation.

Hello, Zag

Features

Quick Start

zig build                             # build the compiler
./bin/zag    test/examples/hello.zag  # emit Zig source (default)
./bin/zag -t test/examples/hello.zag  # dump token stream
./bin/zag -s test/examples/hello.zag  # print S-expressions
./bin/zag -r test/examples/hello.zag  # compile and run

Pipeline

Zag source → S-expressions → type resolution → Zig source → native binary.

The parser is generated by Nexus, a universal grammar engine shared across projects.