flang the compiler proves your program cannot hang 0.6.2 GitHub Русский

The catalogue of examples

Every example program in flang lives in one directory — examples/: 190 files in twenty-one sets and one full-size project. There is no second directory of examples in the repository: until 24 August 2026 a hundred and fifty programs stood a floor below, and they could not be found at a glance.

The number is recounted by one command: git ls-files examples | grep -c '\.flang$' → 190 (measured 29 August 2026).

The sets

Directory.flang filesAbout what
leetcode/82solutions to LeetCode problems; every file is self-contained on purpose — why, is said in index.json. The account of this set is 82 problems
rosetta/28the canonical Rosetta Code tasks
cat/12category theory on applied problems: arrows with promises of their own, laws, CRDT merge
web/13HTTP: an orders service, the URL shortener and a marketplace API of three services — catalogue, cart, orders
io/8I/O orders: a binary file there and back, octets over the wire, a child process, an HTTPS request, a temporary directory, parsing a packet
crypto/8AES, ECDSA, X25519, X.509, a revocation list, a TLS hello — on real test vectors that lie next to them
library-api/7the domain half of a library REST service: lending, catalogue, fines. The only set that shows a project layout in full
db/4talking to PostgreSQL (SCRAM included), to Redis, and reading an SQLite file
service-on-processes/4a service on processes rather than on a three-function example: the claim about an own alternative to OTP, checked at full size
https/3TLS: the RFC 8448 records, the system trust store, a hello to a real host
proof-probes/3probes of the proof core itself: the typed-AST door, a refused generic descent, a variant with fields
driver/2hardware drivers where every function must provably terminate: a UART and an MSI
measure/3termination by a declared measure: Euclid, binary search, natural numbers
errors/2failure as a value rather than a crash: summing a column of numbers that arrived as strings, parsing numbers
surfaces/2factorial on the Chinese and the Esperanto surface of the language
wal/2a write-ahead log: parsing, printing, recovery after a truncation
monad/1an order total written in the в монаде form
money/1money on the exact decimal type сотых
paths/1the shortest path over a network with unreachable nodes
allocator/1a memory allocator as a pure automaton: can malloc be written in flang, and what does the kernel take about it
host-boundary/1the seam: flang decides, a C host executes — printed to C, built with the system cc, run whole
service/1asking a service
import-check.flang1a probe of linking modules by name

How to run them

Examples are declared inside functions rather than in separate check files, and they are run by the binary:

bootstrap/flang test examples/rosetta/   # one set
bootstrap/flang test examples/           # the whole catalogue, 190 files

The sets cost very different amounts, and that is worth knowing before you start. The run of 24 August 2026: leetcode — 82 files, 804 examples, 12 seconds (that set holds 806 examples today); crypto — 8 files, 1223 examples, 39 minutes, because it computes real AES and ECDSA test vectors. A file the binary did not accept is named together with the refusal code rather than skipped in silence.

About library-api

library-api stands apart in this row, and that is the only thing in which the sets here differ from one another. The other twenty-one are programs: a file with declarations that carry their own examples. library-api is a project: seven flang modules, one of them its own, with a directory layout of its own. The example shows not HTTP but a border: what moves into the language, where a piece of logic has a runnable example, and what stays with the host. The host here was on Node and was removed on 20 August 2026 together with the rest of the JavaScript scaffolding; the flang half remained and is checked by a command. The rules drawn from this layout are collected in the repository layout.

Where to go next