Skip to content

Commit c87993b

Browse files
jyn514tshepang
authored andcommitted
Clarify cfg(bootstrap) docs
1 parent 26315eb commit c87993b

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

Diff for: src/building/bootstrapping.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -256,6 +256,10 @@ So the stage2 compiler has to recompile `std` for the target.
256256

257257
### Why does only libstd use `cfg(bootstrap)`?
258258

259+
NOTE: for docs on `cfg(bootstrap)` itself, see [Complications of Bootstrapping][complications].
260+
261+
[complications]: #complications-of-bootstrapping
262+
259263
The `rustc` generated by the stage0 compiler is linked to the freshly-built
260264
`std`, which means that for the most part only `std` needs to be cfg-gated,
261265
so that `rustc` can use features added to std immediately after their addition,
@@ -265,7 +269,7 @@ Note this is different from any other Rust program: stage1 `rustc`
265269
is built by the _beta_ compiler, but using the _master_ version of libstd!
266270

267271
The only time `rustc` uses `cfg(bootstrap)` is when it adds internal lints
268-
that use diagnostic items. This happens very rarely.
272+
that use diagnostic items, or when it uses unstable library features that were recently changed.
269273

270274
### What is a 'sysroot'?
271275

0 commit comments

Comments
 (0)