A new rust compiler
// readme
rustc
A hard fork of mrustc with a different goal.
Upstream mrustc is a bootstrapping seed: a C++ program that compiles Rust just
well enough to build the real rustc once, so the official compiler can take
over. We are not bootstrapping. We are turning mrustc into a real, standalone
Rust compiler โ one that stays and is used to build actual projects. (The
compiler binary is therefore called rustc, not mrustc.)
how we get there
Not by chasing a spec, but by making real programs compile and pass their tests.
Every real-world crate we throw at the compiler exposes bugs โ in type inference, in const evaluation, in the C codegen, in an intrinsic. We fix each one in the compiler and lock it in with a small regression test, then add the whole project as a standing test. The suite grows in two directions at once:
- breadth โ more real binaries that build from source and pass their own
tests (
resvgis the first; more follow); - depth โ a one-file regression under
tst/unit/for every compiler bug we fix along the way.
The compiler gets more correct exactly as fast as the set of programs it can build getsโฆ