Built for real programs
Rey combines the performance of a systems language with the clarity of a scripting language. No compromises.
Native Speed
Compiles directly to native machine code via LLVM. Zero GC pauses, predictable performance, and tiny binaries.
Self-Hosting Compiler
The Rey compiler is written in Rey itself. v0.2.0 achieved full self-hosting — a major milestone in the language's maturity.
Clean Syntax
Expressive and readable. Functions, structs, enums, pattern matching, and lambdas with no boilerplate.
Strong Types
Fully inferred type system. Annotate when you want enforcement, omit when the compiler can figure it out.
Modern Stdlib
Vec, HashMap, Result, Option, file I/O, and string utilities built-in. No external dependencies needed.
Simple to Learn
Designed from the ground up to be learnable. The spec fits in a single document. No hidden magic.
Clean, expressive,
no surprises
Structs, enums, and pattern matching work exactly the way you expect. The syntax is designed to be readable at a glance.
The Result type makes error handling explicit without being verbose. No hidden exceptions — just clean control flow.
Full Language Reference →Try Rey in your browser
No install, no compiler setup. Run Rey code directly in the browser and see the output instantly.
Explore examples for closures, structs, enums, pattern matching, and more — all from the playground.
Open Playground →How it works
From source to native binary in one pass. No runtime, no VM.
Hand-written Lexer
The tokenizer is written from scratch — no regex, no generated code. Direct character-by-character scanning for maximum control and performance.
Recursive Descent Parser
A clean recursive descent parser produces a typed AST. Error messages are precise and point to the exact location of the problem.
LLVM Backend
Code generation targets LLVM IR, which means Rey benefits from decades of optimization work. Release builds are fast and compact.
Help build something great
Rey is open source and early-stage. There are plenty of high-impact areas to contribute to — from the compiler to documentation.