Open
Description
(Split from of rust-lang/rfcs#1133)
Assuming #5002 shakes out in some fashion, we need to elaborate crates without explicit standard library dependencies to have them, so they can be practically used together with crates that do.
https://github.com/Ericson2314/rust-rfcs/blob/cargo-libstd/text/0000-cargo-libstd-awareness.md#implicit-dependencies was the section that covered this in my old RFC. I think it still reads fine but I'll double check and port over.
Key points to think about in any even
- Any explicit stdlib deps at all means no implicit deps. Otherwise hard to reason about / teach. This is a simplification of what I proposed in the RFC.
- Need additional way to opt-out for
core
, as it has no dependencies whatsoever. - All components (library, exes, tests, benches) get an implicit
std
dependency. (That would be all 3 of[dependencies]
[dev-dependencies]
and[build-dependencies]
. - Would be cleaner to to do explicit
core
deps, but our hands our probably tied by back-compat. test
is a bit tricky because of the way it interacts with the built-in test harness. Ideally IMO they would both be normal crates, the harness a procedural macro of sorts. I don't want to grandfather intest
being the only dep needed for both, precluding making thetest-harness
macro crate down the road.