A programming language is much more than its compiler and standard library. It's a community. Tools. Documentation. An ecosystem. All of these elements affect how a language feels, how productive it is, and how applicable it is.
Rust is a very young language -- barely a year past 1.0 -- and building out and maturing the full complement of ecosystem and tooling is crucial to its success. That building is happening, but sometimes at an explosive rate that makes it hard to track what's going on, to find the right library for a task, or to choose between several options on crates.io. It can be hard to coordinate versions of libraries that all work well together. And we lack tools to push toward maturity in a community-wide way, or to incentivize work toward a common quality standard.
On the other hand, the core parts of Rust get a tremendous amount of focus. But we have tended to be pretty conservative in what is considered "core": today, essentially it's rustc
, cargo
, libstd
/libcore
, and a couple of other crates. The standard library also takes a deliberately minimalistic approach, to avoid the well-known pitfalls of large standard libraries that are versioned with the compiler and quickly stagnate, while the real action happens in the broader ecosystem ("std
is where code goes to die").
In short, there are batteries out there, but we're failing to include them (or even tell you where to shop for them).
Can we provide a "batteries included" experience for Rust that doesn't lead to stagnation, one that instead works directly with and through the ecosystem?
I think we can, and I want to lay out a plan that's emerged after discussion with many on the core and subteams.
What is "The Rust Platform"?
The core ideas here draw significant inspiration from the Haskell Platform, which is working toward similar goals for Haskell.
The basic idea of the Rust Platform is simple:
-
Distribute a wide range of artifacts in a single "Rust Platform Package", including:
- The compiler, Cargo, rust-lang crates (e.g.
std
,libc
), docs - Best-of-breed libraries drawn from the wider ecosystem (going beyond rust-lang crates)
- Best-of-breed Tools drawn from the wider ecosystem (e.g.
rustfmt
,clippy
, NDKs, editor plugins, lints) - Cross-compilation targets
- "Language bridges": integration with other languages like JS, Ruby, Python, etc.
- The compiler, Cargo, rust-lang crates (e.g.
-
Periodically curate the ecosystem, determining consensus choices for what artifacts, and at what versions, to distribute.
In general, rustup is intended to be the primary mechanism for distribution; it's expected that it will soon replace the guts of our official installers, becoming the primary way to acquire the Rust Platform and all that comes with it.
As you'd expect, the real meat here is in the details. For example, it's probably unclear what it even means to "distribute" a library, given Cargo's approach to dependency management. Read on!
This is the dedicated discuss post for feedback on the proposal. Fire away!