You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/stabilization_guide.md
+7-4Lines changed: 7 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -29,7 +29,7 @@ Places that may need updated documentation include:
29
29
If you're not sure, please open an issue on this repository and it can be discussed.
30
30
- Standard library documentation: This is updated as needed.
31
31
Language features often don't need this, but if it's a feature that changes how idiomatic examples are written, such as when `?` was added to the language, updating these in the library documentation is important.
32
-
Review also the keyword documentation and ABI documentation in the standard library, as these sometimes needs updates for language changes.
32
+
Review also the keyword documentation and ABI documentation in the standard library, as these sometimes need updates for language changes.
33
33
-[Rust by Example]: This is updated as needed.
34
34
35
35
Prepare PRs to update documentation involving this new feature for the repositories mentioned above.
@@ -63,7 +63,8 @@ Before the stabilization will be considered by the lang team, there must be a co
63
63
64
64
There is a central listing of unstable feature-gates in [`compiler/rustc_feature/src/unstable.rs`].
65
65
Search for the `declare_features!` macro.
66
-
There should be an entry for the feature you are aiming to stabilize, something like (this example is taken from [rust-lang/rust#32409]:
66
+
There should be an entry for the feature you are aiming to stabilize,
67
+
something like the following (taken from [rust-lang/rust#32409]:
67
68
68
69
```rust,ignore
69
70
// pub(restricted) visibilities (RFC 1422)
@@ -85,7 +86,9 @@ When it is done, it should look like:
85
86
### Removing existing uses of the feature-gate
86
87
87
88
Next, search for the feature string (in this case, `pub_restricted`) in the codebase to find where it appears.
88
-
Change uses of `#![feature(XXX)]` from the `std` and any rustc crates (this includes test folders under `library/` and `compiler/` but not the toplevel `tests/` one) to be `#![cfg_attr(bootstrap, feature(XXX))]`.
89
+
Change uses of `#![feature(XXX)]` from the `std` and any rustc crates
90
+
(which includes test folders under `library/` and `compiler/` but not the toplevel `tests/` one)
91
+
to be `#![cfg_attr(bootstrap, feature(XXX))]`.
89
92
This includes the feature-gate only for stage0, which is built using the current beta (this is needed because the feature is still unstable in the current beta).
90
93
91
94
Also, remove those strings from any tests (e.g. under `tests/`). If there are tests specifically targeting the feature-gate (i.e., testing that the feature-gate is required to use the feature, but nothing else), simply remove the test.
0 commit comments