An experimental systems language called Goose is proposing a distinctive route to memory safety: programs have no heap, garbage collector or manually written lifetime annotations. Instead, dynamic values live inline on compiler-managed data stacks, grow through pointer bumps and disappear when their scopes end. The project presents that model as a way to combine predictable memory behavior with familiar C- and Rust-like syntax.
Goose’s author says the compiler determines how many data stacks a program needs. At most one resizable value can occupy the top of each stack, allowing it to grow without relocating existing data. References and slices carry a statically tracked root that identifies the variable owning the referenced storage. The compiler checks that references do not outlive their roots and are not observed through an invalid type, while inferring those relationships rather than requiring explicit lifetime syntax.
The design has consequences for data layout. Arrays, strings and variable-sized fields are stored inline rather than through pointers to separately allocated blocks. The project’s documentation gives an example record occupying 29 bytes with no allocations, compared with larger representations using a C++ string and vector or Rust String and Vec. An array containing variable-sized elements can be traversed sequentially but cannot offer ordinary random indexing, illustrating one of the trade-offs created by the layout.
Goose also offers fixed- and variable-sized representations for algebraic data types. Fixed mode reserves enough room for the largest possible variant, while variable mode stores each value at its actual size. Relative references can be represented as offsets, enabling position-independent structures that the project says can be written to storage and loaded without pointer repair. Its `from_bytes` mechanism validates framing, tags, lengths and links before treating external bytes as a value.
For concurrency, the language does not allow shared mutable memory. Threads are compiled with separate stacks and global data, and values cross typed queues only when they contain no references. Goose emits a single C file for compilation and supports a C foreign-function interface for values with compatible layouts.
The repository advertises benchmark results faster than comparable C++ and safe Rust implementations while using less memory. Those figures come from the project itself and should be treated as early, workload-specific results rather than an independent verdict on general performance. The documentation says its benchmark suite includes losses as well as wins, and provides a tutorial, specification and 26 sample programs.
Goose is therefore best understood as a research-like language experiment. Its stack-only restriction may yield impressive locality and simple reclamation in suitable programs, but it also reshapes commonplace operations and data structures. Broader conclusions will require outside testing, mature tooling and experience with applications beyond the project’s own examples.



