Repository navigation
Home
Tycho is an experimental systems language built to test one idea: implicit hierarchical arenas under value semantics. Each scope owns a memory arena, freed when the scope exits; with no reference type in the language, the compiler sees every value's lifetime from the syntax alone and inserts every allocation and free itself. The result is automatic memory management — no garbage collector, no manual free — from lexical scope rather than a runtime. It transpiles to C and builds with cc and make.
It's a research project — an experiment testing that one idea — not a production language. But it's a heavily-checked one, and that's the part most experiments this young skip; see Is it production-ready? in the FAQ.
fn greet(name: string) -> string:
return "hello " + name
fn main():
name := input()
println(greet(name))
-
Install Tycho — a C compiler and
make, nothing else to install. - Tutorial — from hello-world to a real program in about an hour.
- The thesis — the one idea, with the measurements and the places it costs.
-
From
mallocto arenas — the memory model, explained from the C you already know.
The reader documentation is mirrored into this wiki — see the Documentation Map for the full index of the reference and the how-to guides. The canonical source stays in the repo under /docs, and the formal language specification lives there.
- FAQ — garbage collector? references? production-ready? how fast?
- Documentation Map — reference, guides, spec.
- Contributing — the two-compiler discipline and the local gate.
- Website — https://tycho-lang.com
- Source — https://github.com/StefanVonRanda/tycho
- License — MIT
The reader docs here are mirrored from /docs in the repo — the canonical source. · tycho-lang.com · MIT licensed
- Tutorial
- The Tycho thesis: value semantics makes implicit arenas work
- Architecture & project status
- From
mallocto implicit arenas
- Tycho language reference
- Basics
- Types
- Functions and closures
- Structs and tuples
- Enums, options, and
match - Arrays and slices
- Subscripts (user-defined projections)
- Maps
- Generics
- Concurrency
- FFI (calling C)
- Packages
- Builtins
- Memory model in the self-hosted compiler
- Tycho aggregates: arrays & structs under value semantics
- Maps with arbitrary value types
m[k]as a place: in-place map-value mutation- Generics (monomorphized)
- Concurrency in Tycho
- FFI — calling C from Tycho
- Packages & modules
- corelib — Tycho's standard library
- Performance: the self-hosted transpiler vs the C one
- Debugging generated C