bork is a programming language for backend services. These pages describe the language as it works today.
- A tour of bork: install the compiler and build a small program step by step.
- Browser playground: check code, inspect types, and format a file without installing anything.
- Examples: complete programs to read and run.
Each page covers one area in plain terms, with code you can run.
| Page | What it covers |
|---|---|
| Scripts | Executable single files, top-level statements, shebangs, and inline Go dependencies |
| Basics | Names, functions, expressions, numbers, strings, runes, lambdas, and methods |
| Types | Records, sealed types, unions, Option, Ok, and generics |
| Matching and errors | match, patterns, exhaustiveness, and ? |
| Collections | Lists, maps, lazy sequences, bytes, and parallel list operations |
| Facts | Predicates, where, and what the compiler proves |
| Effects | uses, pure functions, and ambient values |
| Scopes and tasks | Resources, tasks, channels, shared state, cancellation, and lazy and async bindings |
| Compile-time evaluation | comptime blocks and reading files at build time |
| Typed interpolation | s"...", sql.SQL"...", and defining your own prefix |
| Packages and type classes | Packages, modules, imports, type classes, derived instances, and dependency assembly |
| Calling Go | unsafe go, bindings to Go functions, and Go dependencies |
| Testing | Tests, snapshots, mocks, and property tests |
- The bork command: every command, the settings, and the compile cache.
- Standard packages: files, HTTP, JSON, SQL, time, and more.
- Editor support and VS Code:
bork lspchecks unsaved buffers and supplies navigation, completion and formatting. - JSON diagnostics, watch mode, and compiler code queries: the compiler's interfaces for editors and tools.
- Contributing and design notes: the grammar, the full requirements, and the design documents.