The Goose programming language: everything about the new language that promises to beat C++ and Rust
Goose is a new systems language with no heap, no garbage collector and no lifetime annotations. Its author says it runs more than 3x faster than idiomatic C++. How it works and whether it’s worth trying.

One of the most discussed topics among developers in recent weeks is the Goose programming language. It was created by Wouter van Oortmerssen, a veteran programmer and the author of the Lobster language. Goose is open source under the Apache 2.0 license, and, most interestingly, its author says the compiler was produced almost entirely with AI, from a human-designed language specification.
The core idea: no heap
In most languages, dynamic data such as arrays and strings lives on the heap and needs a garbage collector (Java, Go), reference counting (Swift) or lifetime rules (Rust) to manage it. Goose uses none of these. According to its documentation, every dynamic value lives on data stacks managed by the compiler.
- Each stack is a large address-space reservation (2GB by default) with a simple bump pointer
- Only one resizable value is live per stack at a time, and it is always on top
- Growing an array just advances the pointer — nothing is moved
- Freeing memory at scope exit is a single store
The compiler proves these rules at compile time; at runtime only the bump pointers are tracked.
Read alsoDiscord rewritten in Rust: new client is faster and uses 70% less RAMHow safety works
Every reference has a static “root” — the variable that bounds its lifetime. The compiler infers roots on its own and rejects references that would outlive their owner. Unlike Rust, programmers write no lifetime annotations, and there is no unsafe.
A taste of the syntax
Goose has a compact, C-like syntax. A struct with variable-size data is declared like this: struct Item { sku: u8[varint], qty: varint, cents: varint }. There are three kinds of arrays: fixed-size, grow-only and grow-shrink.
Speed: the author’s numbers
The author published results across 16 benchmarks (geometric mean). According to them, Goose is:
- about 3.3–3.5x faster than idiomatic C++
- 1.16–1.26x faster than hand-optimized C++
- 1.12–1.19x faster than the best safe Rust
- using 1.2–1.9x less memory
For example, an order record takes 29 bytes and zero allocations in Goose, versus 160 bytes and one allocation in C++ and 153 bytes and four allocations in Rust. Keep in mind these are the author’s own benchmarks; independent verification is still limited.
Limitations
- Recursive functions cannot keep growable data across a recursive call
- No escaping closures or function pointers
- Whole-program compilation only
- The library ecosystem is still very small
How to try it
Prebuilt compilers are available for Windows x64, Linux x64 and macOS (Apple silicon and Intel). Goose compiles to a single C file, so it runs anywhere a C compiler does. Download a release from the aardappel/goose page on GitHub, add the folder to your PATH and run a sample with goose samples/01_tour.goose. A VS Code extension is included in the archive.
The verdict
Goose is a fascinating experiment with a genuinely new approach to memory management. Systems programmers who care about performance should follow it and give it a try. But the language is new: for production use, it is wise to wait for independent benchmarks and a bigger ecosystem.
Source: Goose (aardappel)



