#include <name>, the library inside the binary - mc carries its own source inside the executable, compressed, and its standard library in a tree beside it — lib/mc/v<version>/, what a release tarball unpacks next to the binary. Both are served through the angle-bracket form of #include, and a program cannot tell which of the two answered: no checkout, no include path, no install step.
Every command, flag and dump - mc has one binary and one entry point per registered subcommand: the single-file compiler, then build, limits, sysroot, pkg, update, install, upgrade and sandbox. Everything below is read off src/cli.mc (the single-file CLI) and the file that registers each subcommand — src/driver.mc, src/sysroot.mc, src/pkg.mc, src/install.mc, src/upgrade.mc, src/sandbox.mc. The list is the subcommand TABLE, so a taught compiler that registers one more prints one more line; mc with no argument prints it and exits 1:
Every message the compiler emits - Every diagnostic mc can print, with what causes it and what to do about it. The list is extracted from the die/die2/err_at/err_at2/err_node/expect/toml_err* call sites in src/*.mc; nothing here is invented, and scripts/check-docs.sh compiles a sample for the ones marked with an example.
The ten # directives - A directive is a #name at the start of a line-ish position, processed at compile time, in source order, mutating the compiler's own tables as the parse goes. There are exactly ten, and the list is dir_index() in src/lex.mc:
The parser and hook API - Everything a module may call to teach the compiler, with its exact signature, when the compiler calls it, what it returns, and what it refuses. This is the API of Tier 2 (passes and backends) and Tier 3 (syntax taught by code).
The core language - The core is what stage0/*.c and src/*.mc implement between them: the language mc compiles before any teaching happens. Everything else in this reference — #rule, syntax, pass, backend — builds on top of it and is described in directives.md and hooks.md.
The machine task contract - This whole page is frozen surface: the contract's version (one line, extracted by scripts/surface-extract.sh as the machine kind) may only go up, and only in a commit that adds a Version N → M paragraph like the ones below — check-freeze enforces both (hooks.md § 8).
The object model and the codegen API - Between the AST and the file on disk there is one format-neutral layer: sections, symbols and relocations in src/objmodel.mc, and a per-function buffer of Ins records in src/gen_walk.mc. Five backends are built on nothing but this — macho, macho-exe, elf-obj, elf-obj-x86_64 and coff-obj-arm64 — and so is lib/backend_arm64.mc, which reimplements the whole AArch64 encoder from outside and produces byte-identical objects.
Packages - Trust. A library package is source mc compiles; a compiler-module package is code that RUNS on your machine at build time, inside the taught compiler mc build spawns. The brakes are the lock (nothing runs that is not the bytes you reviewed) and the closure rule (a package reads its own tree, libraries the binary ships, and its declared dependencies — nothing else). They do not stop a module that opens a file through an extern. Until mc sandbox wraps the spawn, a compiler-module package is trusted code.
mc sandbox — compile and run an arbitrary program in isolation - Status: complete (M43, four steps; the CI job of step D is what proves the unprivileged path). The box is there — namespaces, a mount tree, pivot_root, the caps, the steps, the wall clock and the report — and so are the two walls that make a refusal a sentence: a Landlock ruleset over the box's roots and a seccomp filter whose default action is not a kill but a question to the supervisor. A program that reaches outside the box is named and the box stops:
Sysroots — where a cross link finds its files - A cross link needs files mc does not write: musl's crt1.o, crti.o, crtn.o and libc.a for a Linux target, an import library for a Windows one, an SDK (or a stub) for the .o + ld road on macOS. {sysroot} in [linker].args is where they come from, and this page is the whole story of how that placeholder is resolved.
mc.toml, every key - mc build [DIR] reads DIR/mc.toml (or --config FILE). Every path in the file is relative to the directory of the config, never to the working directory, so mc build examples/api from the repository root does exactly what mc build does from inside examples/api.
mc tool — install and run a program package - A tool is a package of kind = "exe": a program mc tool install builds on your own machine with the compiler that is running, and mc tool run runs — boxed under the permissions the package declared and you confirmed, on a host that has a sandbox, and directly on one that does not. It is the package half of the registry aimed at programs rather than libraries (a library is kind = "obj" or has no [project], is compiled into your own code, and is never installed).