Statically typed. Compiled to native binaries. Built-in concurrency, real macros, and OOP without the boilerplate.
A small core, carefully chosen. Familiar syntax from Java and Kotlin, with the safety of Rust's type system underneath.
No mandatory main(). No public-static-void boilerplate. Write five lines and run them. Scale into a full app when you're ready.
Classes, interfaces, generics, data classes. Auto-generated equals, copy, and toString. No 80-line POJOs.
Fiber, Thread, VirtualThread — same API, different runtime strategies. Channels and Mutex included.
Match on literals, ranges, types, and destructured data classes. With guards and exhaustiveness checking.
Errors are values. Match on Ok and Err. The compiler ensures you handle both. No more NullPointerException.
Write macros in Emerald itself. Manipulate the AST at compile time. Zero runtime cost.
Three tiers for three workloads. Same API for all three. The visualization below is real timing — three slowDouble() calls run concurrently, each sleeps a different amount, all results sum to 120.
Annotations transform your code into something larger. Pick a built-in below to see what the compiler generates. Zero runtime cost — it's all done before your binary is built.
Emerald compiles to Crystal source, which Crystal compiles via LLVM. You get a single, dependency-free binary. No VM. No runtime to install.
Emerald is built on Crystal. You'll need Crystal 1.20+ installed. Then clone, build, and write your first .ems file.
$ git clone https://github.com/syntaxjason/emerald $ cd emerald/compiler $ shards build --release Then build your first program: $ ./bin/emeraldc build hello.ems -o hello $ ./hello Hello, Emerald!