Skip to content

Commit 86f72e4

Browse files
committed
Use true defaults to avoid double negatives as suggested by @Valloric
1 parent eee7dba commit 86f72e4

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

text/0000-cargo-libstd-awareness.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -35,16 +35,16 @@ above, with Cargo being none the wiser.
3535
The only new interface proposed is a boolean field to the package meta telling Cargo that the
3636
package does not depend on libstd by default. This need not imply Rust's `no_std`, as one might want
3737
to `use` their own build of libstd by default. To disambiguate, this field is called
38-
q`no-implicit-deps`; please, go ahead and bikeshead the name. `no-implicit-deps` is false by
39-
default to maintain compatibility with existing packages.
38+
`implicit-deps`; please, go ahead and bikeshead the name. `implicit-deps` is true by default to
39+
maintain compatibility with existing packages.
4040

4141
The meaning of this flag is defined in 3 phases, where each phase extends the last. The idea being
4242
is that while earlier phases are easier to implement, later phases yield a more elegant system.
4343

4444
## Phase 1
4545

46-
Add a `--no-sysroot` flag to `rustc`, and pass that to `rustc` is the case that `no-implicit-deps`
47-
is true.
46+
Add a `--use-sysroot=<true|false>` flag to `rustc`, were true is the default. Make cargo pass
47+
`--use-sysroot=false` to `rustc` is the case that `implicit-deps` is false.
4848

4949
This hotfix is enough to allow us bare-metal devs to use Cargo for our own projects, but doesn't
5050
suffice for creating an ecosystem of packages that depend on crates behind the facade but not libstd
@@ -53,8 +53,8 @@ the crates behind the facade, or they don't depend on them at all.
5353

5454
## Phase 2
5555

56-
Since, passing in a directory of crates is inherently more fragile than passing in a crate
57-
itself, make Cargo use `--no-sysroot` in all cases.
56+
Since, passing in a directory of crates is inherently more fragile than passing in a crate itself,
57+
make Cargo use `--use-sysroot=false` in all cases.
5858

5959
Cargo would special case package names corresponding to the crates behind the facade, such that if
6060
the package don't exist, it would simply pass the corresponding system crate to `rustc`. I assume
@@ -75,7 +75,7 @@ package names can be treated normally,
7575

7676
The standard library is be downloaded and built from crates.io. Or equivalently, Cargo comes with a
7777
cache of that build, as Cargo should be able cache builds between projects at this point. Just as in
78-
phase 2, `no-implicit-deps` just prevents libstd from implicitly being appended to the list of
78+
phase 2, `implicit-deps = false` just prevents libstd from implicitly being appended to the list of
7979
dependencies.
8080

8181
Again, to make this as least controversial as possible, this RFC does not propose outright that the

0 commit comments

Comments
 (0)