Mux is a statically-typed, reference-counted language that combines Python's readability, Go's simplicity, and Rust's type safety - compiled to native code via LLVM.
// Error handling with Result types
func divide(int a, int b) returns result<int, string> {
if b == 0 {
return err("division by zero")
}
return ok(a / b)
}
// Pattern matching with exhaustive checking
func main() returns void {
match divide(10, 2) {
ok(value) {
print("Result: " + value.to_string())
}
err(error) {
print("Error: " + error)
}
}
}
# Install (Linux/macOS)
curl -fsSL https://raw.githubusercontent.com/muxlang/mux-compiler/main/scripts/install.sh | sh
# Run your first program
mux run hello.muxOr skip the install and try it in the playground.
- Simple & readable - clean, semicolon-free syntax with Python-like clarity.
- Type safe - strong static typing, no implicit conversions, errors caught at compile time.
- Fast & native - LLVM-powered compilation to real native binaries.
- Memory safe - reference counting, no GC pauses and no borrow-checker ceremony.
- Modern - generics, interfaces, tagged unions, and exhaustive pattern matching.
| Repo | What it is |
|---|---|
| mux-compiler | The compiler + CLI (lexer, parser, semantics, LLVM codegen). The canonical "Mux version". |
| mux-runtime | Runtime + standard library for compiled programs. Plain stable Rust, no LLVM. Published to crates.io. |
| mux-website | The documentation site (mux-lang.dev) + the docs AI assistant + indexing tools. |
| mux-website-api | The Fly.io compile/run API behind the playground. |
| tree-sitter-mux | Tree-sitter grammar + highlight queries (Neovim, Helix, Emacs). |
| mux-syntax-highlighting | TextMate grammar, VSCode extension, editor configs, and the canonical syntax spec. |
| mux-context | Cross-repo knowledge hub: architecture, design rationale, feature map, glossary, and the release process. |
- New to the language? Start with the docs.
- Curious how it fits together? Read mux-context.
- Want to contribute? Each repo has its own
README.mdandAGENTS.md; shared guidelines live in CONTRIBUTING.md. - Found a bug or have an idea? Open an issue in the relevant repo - or, if you're unsure which, in mux-context for triage.
Mux is MIT-licensed and welcomes contributions.