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
This PR contains a number of changes to better describe our
stabilization process and policies. Let's revise this a bit,
editorially, to better describe some of the nuances in our process,
and to capture some additional details we want people to speak to in
their stabilization reports.
Once the implementation is complete, the feature will be available to nightly users, but not yet part of stable Rust. This is a good time to write a blog post on [the main Rust blog][rust-blog] and issue a **Call for Testing**.
212
+
Once the implementation is complete, the feature will be available to nightly users but not yet part of stable Rust. This is a good time to write a blog post on [the main Rust blog][rust-blog] and issue a "call for testing".
213
213
214
-
Some example Call for Testing blog posts:
214
+
Some earlier such blog posts include:
215
215
216
216
1.[The push for GATs stabilization](https://blog.rust-lang.org/2021/08/03/GATs-stabilization-push/)
217
217
2.[Changes to `impl Trait` in Rust 2024](https://blog.rust-lang.org/2024/09/05/impl-trait-capture-rules.html)
218
218
3.[Async Closures MVP: Call for Testing!](https://blog.rust-lang.org/inside-rust/2024/08/09/async-closures-call-for-testing/)
219
219
220
-
Alternatively, [*This Week in Rust*][twir] has a [call-for-testing section][twir-cft]. Example:
220
+
Alternatively, [*This Week in Rust*][twir] has a [section][twir-cft] for this. One example of this having been used is:
221
221
222
-
-[Call for testing on boolean literals as cfg predicates](https://github.com/rust-lang/rust/issues/131204#issuecomment-2569314526).
222
+
-[Call for testing on boolean literals as cfg predicates](https://github.com/rust-lang/rust/issues/131204#issuecomment-2569314526)
223
223
224
-
Which option to choose might depend on how significant the language change is, though note that [*This Week in Rust*][twir]'s Call for Testing section might be less visible than a dedicated post on the main Rust blog.
224
+
Which option to choose might depend on how significant the language change is, though note that the [*This Week in Rust*][twir] section might be less visible than a dedicated post on the main Rust blog.
225
225
226
226
## Affiliated work
227
227
228
-
Once the feature is supported by rustc, there is other associated work that needs to be done to give users a complete experience. Think of it as the *language toolchain* developer experience, which doesn't only comprise of the language or compiler in isolation.
228
+
Once the feature is supported by rustc, there is other associated work that needs to be done to give users a polished experience when using all of the tools we ship.
229
229
230
230
- Documenting the language feature in the [Rust Reference][reference].
231
-
-(If applicable) Extending [`rustfmt`] to format any new syntax.
232
-
-(If applicable) Extending [`rust-analyzer`]. This can depend on the nature of the language feature, as some features don't need to be blocked on *full* support.
233
-
-A blocking concern is when a language feature degrades the user experience simply by existing before its support is implemented in [`rust-analyzer`].
234
-
-Example blocking concern: new syntax that [`rust-analyzer`] can't parse -> bogus diagnostics, type inference changes -> bogus diagnostics.
231
+
- Extending [`rustfmt`] to format any new syntax (if applicable).
232
+
- Extending [`rust-analyzer`] (if applicable). The extent of this work can depend on the nature of the language feature, as some features don't need to be blocked on *full* support.
233
+
-When a language feature degrades the user experience simply by existing before support is implemented in [`rust-analyzer`], that may lead the lang team to raise a blocking concern.
234
+
-Examples of such might include new syntax that [`rust-analyzer`] can't parse or type inference changes it doesn't understand when those lead to bogus diagnostics.
235
235
236
236
## Stabilization
237
237
238
-
The final step in the feature lifecycle is [stabilization][stab], which is when the feature becomes available to all Rust users. At this point, backwards incompatible changes are no longer permitted (modulo soundness bugs and inference changes; see the lang team's [defined semver policies](https://rust-lang.github.io/rfcs/1122-language-semver.html) for full details). To learn more about stabilization, see the [stabilization guide][stab].
238
+
The final step in the feature lifecycle is [stabilization][stab], which is when the feature becomes available to all Rust users. At this point, backward incompatible changes are generally no longer permitted (see the lang team's [defined semver policies](https://rust-lang.github.io/rfcs/1122-language-semver.html) for details). To learn more about stabilization, see the [stabilization guide][stab].
Copy file name to clipboardExpand all lines: src/stabilization_guide.md
+17-19Lines changed: 17 additions & 19 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -47,27 +47,23 @@ Author a stabilization report using the [template found in this repository][srt]
47
47
48
48
Stabilization reports summarize:
49
49
50
-
- The main design decisions and deviations since the RFC was accepted, particularly decisions that were FCP'd or otherwise accepted by the language team.
51
-
- Quite often, the final stabilized language feature can have significant design deviations from the original RFC text.
50
+
- The main design decisions and deviations since the RFC was accepted, including both decisions that were FCP'd or otherwise accepted by the language team as well as those being presented to the lang team for the first time.
51
+
- Quite often, the final stabilized language feature can have significant design deviations from the original RFC text. That's OK, but these deviations must be highlighted and explained carefully.
52
52
- The work that has been done since the RFC was accepted, acknowledging the main contributors that helped drive the language feature forward.
53
53
54
-
The [*Stabilization Template*][srt] includes a series of questions that aim to surface interconnections between this feature and the various Rust teams (lang, types, etc) and also to identify items that are commonly overlooked.
54
+
The [*Stabilization Template*][srt] includes a series of questions that aim to surface connections between this feature and lang's subteams (e.g. types, opsem, lang-docs, etc.) and to identify items that are commonly overlooked.
55
55
56
56
[srt]: ./stabilization_report_template.md
57
57
58
58
The stabilization report is typically posted as the main comment on the stabilization PR (see the next section).
59
59
60
60
## Stabilization PR for a language feature
61
61
62
-
*This is for stabilizing language features. If you are stabilizing a library
63
-
feature, see [the stabilization chapter of the std dev guide][std-guide-stabilization] instead.*
62
+
*This is for stabilizing language features. If you are stabilizing a library feature, see [the stabilization chapter of the std dev guide][std-guide-stabilization] instead.*
64
63
65
-
Here is a general guide to how to stabilize a feature --
66
-
every feature is different, of course, so some features may
67
-
require steps beyond what this guide talks about.
64
+
Here is a general guide to how to stabilize a feature -- every feature is different, of course, so some features may require steps beyond what this guide discusses.
68
65
69
-
Note: Before we stabilize any feature, it's the rule that it
70
-
should appear in the documentation.
66
+
Note: Before the stabilization will be considered by the lang team, there must be a complete PR to the Reference describing the feature, and before the stabilization PR will be merged, this PR must have been reviewed and accepted by the lang-docs team.
71
67
72
68
### Updating the feature-gate listing
73
69
@@ -166,22 +162,24 @@ if something { /* XXX */ }
166
162
167
163
## Team nominations
168
164
169
-
After the stabilization PR is opened with the stabilization report, wait a bit for potential immediate comments. When such immediate comments "simmer down" and you feel the PR is ready for consideration by the lang team, you can [nominate the PR](https://lang-team.rust-lang.org/how_to/nominate.html) to get it on the list for discussion in the next meeting. You should also cc the other interacting teams when applicable to review the language feature being stabilized and the stabilization report:
165
+
When opening the stabilization PR, CC the lang team (`@rust-lang/lang`) and any other teams to whom the feature is relevant, e.g.:
170
166
171
-
*`@rust-lang/types`, to look for type system interactions
172
-
*`@rust-lang/compiler`, to review implementation robustness
173
-
*`@rust-lang/opsem`, if this feature interacts with unsafe code and can create undefined behavior
174
-
*`@rust-lang/libs-api`, if there are additions to the standard library that affects standard library API or their guarantees
167
+
-`@rust-lang/types`, for type system interactions.
168
+
-`@rust-lang/compiler`, for implementation robustness.
169
+
-`@rust-lang/opsem`, for interactions with unsafe code.
170
+
-`@rust-lang/libs-api`, for changes to the standard library API or its guarantees.
171
+
-`@rust-lang/lang-docs`, for questions about how this should be documented in the Reference.
175
172
176
-
If you are not an organization member, you can simply ask your assigned reviewer to cc the relevant teams on your behalf.
173
+
After the stabilization PR is opened with the stabilization report, wait a bit for any immediate comments. When such comments "simmer down" and you feel the PR is ready for consideration by the lang team, [nominate the PR](https://lang-team.rust-lang.org/how_to/nominate.html) to get it on the agenda for consideration in an upcoming lang meeting.
174
+
175
+
If you are not a `rust-lang` organization member, you can ask your assigned reviewer to CC the relevant teams on your behalf.
177
176
178
177
## FCP proposed on the PR
179
178
180
-
Finally, some member of the team responsible for tracking this feature agrees with stabilizing this feature, will
181
-
start the FCP (final-comment-period) process by commenting
179
+
After the lang team and other relevant teams review the stabilization, and after you have answered any questions they may have had, a member of one of the teams may propose to accept the stabilization by commenting:
182
180
183
181
```text
184
182
@rfcbot fcp merge
185
183
```
186
184
187
-
The rest of the team members will review the proposal. If the final decision is to stabilize, the PR will be reviewed by the compiler team like any other PR.
185
+
Once enough team members have reviewed, the PR will move into a "final comment period". After this period, if no new concerns have been raised, the PR can be merged after implementation review in the usual way.
Copy file name to clipboardExpand all lines: src/stabilization_report_template.md
+80-28Lines changed: 80 additions & 28 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,43 +2,63 @@
2
2
3
3
> **What is this?**
4
4
>
5
-
> This is a template to use for [stabilization reports](./stabilization_guide.md) of **language features**. It consists of a series of questions that aim to provide the information most commonly needed and to help reviewers be more likely to identify potential problems up front. Not all parts of the template will apply to all stabilizations. Feel free to put N/A if a question doesn't seem to apply to your case.
5
+
> This is a template to use for [stabilization reports](./stabilization_guide.md) of **language features**. It consists of a series of questions that aim to provide the information most commonly needed. This helps reviewers to identify potential problems up front. Not all parts of the template will apply to every stabilizations. Put N/A if a question doesn't apply.
6
6
>
7
-
> You can copy the following template after the separator and edit it as Markdown, replacing the*TODO*placeholders with answers.
7
+
> Copy the following template after the separator and edit it as Markdown. Replace each*TODO* with answers.
8
8
9
9
---
10
10
11
-
> ## General design
11
+
## General design
12
12
13
-
> ### What is the RFC for this feature and what changes have occurred to the user-facing design since the RFC was finalized?
13
+
### What is the RFC for this feature?
14
14
15
15
*TODO*
16
16
17
-
> ### What behavior are we committing to that has been controversial? Summarize the major arguments pro/con.
17
+
### Post-RFC changes
18
+
19
+
> What user-visible changes have occurred since the RFC was accepted?
18
20
19
21
*TODO*
20
22
21
-
> ### Are there extensions to this feature that remain unstable? How do we know that we are not accidentally committing to those?
23
+
### Key points
24
+
25
+
> What behaviors to be stabilized have been most controversial? Summarize the major arguments on all sides.
22
26
23
27
*TODO*
24
28
25
-
> ## Has a Call for Testing period been conducted? If so, what feedback was received?
26
-
>
27
-
> Does any OSS nightly users use this feature? For instance, a useful indication might be "search <grep.app> for `#![feature(FEATURE_NAME)]` and had `N` results".
29
+
### Nightly extensions
30
+
31
+
> Are there extensions to this feature that remain unstable? How do we know that we are not accidentally committing to those?
28
32
29
33
*TODO*
30
34
31
-
> ## Implementation quality
35
+
## Feedback
36
+
37
+
### Call for testing
38
+
39
+
> Has a "call for testing" been done? If so, what feedback was received?
32
40
33
41
*TODO*
34
42
35
-
> ### Summarize the major parts of the implementation and provide links into the code (or to PRs)
43
+
### Nightly use
44
+
45
+
> Does any OSS nightly users use this feature? For instance, a useful indication might be "search <grep.app> for `#![feature(FEATURE_NAME)]` and had `N` results".
46
+
47
+
*TODO*
48
+
49
+
## Implementation quality
50
+
51
+
### Major parts
52
+
53
+
> Summarize the major parts of the implementation and provide links into the code (or to PRs).
36
54
>
37
55
> An example for async closures: <https://rustc-dev-guide.rust-lang.org/coroutine-closures.html>.
38
56
39
57
*TODO*
40
58
41
-
> ### Summarize existing test coverage of this feature
59
+
### Coverage
60
+
61
+
> Summarize existing test coverage of this feature.
42
62
>
43
63
> Consider what the "edges" of this feature are. We're particularly interested in seeing tests that assure us about exactly what nearby things we're not stabilizing.
44
64
>
@@ -56,50 +76,82 @@
56
76
57
77
*TODO*
58
78
59
-
> ### What outstanding bugs in the issue tracker involve this feature? Are they stabilization-blocking?
79
+
### Outstanding bugs
80
+
81
+
> What outstanding bugs in the issue tracker involve this feature? Are they stabilization-blocking?
82
+
83
+
*TODO*
84
+
85
+
### Outstanding FIXMEs
86
+
87
+
> What FIXMEs are still in the code for that feature and why is it ok to leave them there?
60
88
61
89
*TODO*
62
90
63
-
> ### What FIXMEs are still in the code for that feature and why is it ok to leave them there?
91
+
### Contributors
92
+
93
+
> Summarize contributors to the feature by name for recognition and assuredness that people involved in the feature agree with stabilization.
64
94
65
95
*TODO*
66
96
67
-
> ### Summarize contributors to the feature by name for recognition and assuredness that people involved in the feature agree with stabilization
97
+
### Tool changes
98
+
99
+
> Which tools need to be adjusted to support this feature. Has this work been done?
> What compilation-time checks are done that are needed to prevent undefined behavior?
110
+
>
111
+
> (Be sure to link to tests demonstrating that these tests are being done.)
74
112
75
113
*TODO*
76
114
77
-
> ## Type system and execution rules
115
+
### Sound by default?
78
116
79
-
> ### What compilation-time checks are done that are needed to prevent undefined behavior?
80
-
>
81
-
> (Be sure to link to tests demonstrating that these tests are being done.)
117
+
> Does the feature's implementation need checks to prevent UB or is it sound by default and needs opt in in places to perform the dangerous/unsafe operations? If it is not sound by default, what is the rationale?
82
118
83
119
*TODO*
84
120
85
-
> ### Does the feature's implementation need checks to prevent UB or is it sound by default and needs opt in in places to perform the dangerous/unsafe operations? If it is not sound by default, what is the rationale?
121
+
### Breaks the AM?
122
+
123
+
> Can users use this feature to introduce undefined behavior, or use this feature to break the abstraction of Rust and expose the underlying assembly-level implementation? (Describe.)
86
124
87
125
*TODO*
88
126
89
-
> ### Can users use this feature to introduce undefined behavior, or use this feature to break the abstraction of Rust and expose the underlying assembly-level implementation? (Describe.)
127
+
### Reference
128
+
129
+
> What updates are needed to the Reference? Link to each PR.
130
+
131
+
-*TODO*
132
+
133
+
## Common interactions
134
+
135
+
### Temporaries
136
+
137
+
> Does this feature introduce new expressions that can produce temporaries? What are the lifetimes of those temporaries?
90
138
91
139
*TODO*
92
140
93
-
> ### What updates are needed to the reference/specification? (link to PRs when they exist)
141
+
### Pre-expansion / post-expansion
142
+
143
+
> Does this feature raise questions about what should be accepted pre-expansion (e.g. in code covered by `#[cfg(false)]`) versus what should be accepted post-expansion? What decisions were made about this?
94
144
95
145
*TODO*
96
146
97
-
> ## Common interactions
147
+
### SemVer implications
98
148
99
-
> ### Does this feature introduce new expressions and can they produce temporaries? What are the lifetimes of those temporaries?
149
+
> Does this feature create any new ways in which library authors must take care to prevent breaking their downstreams when making minor-version releases? Describe these. Are these new hazards "major" or "minor" according to [RFC 1105](https://rust-lang.github.io/rfcs/1105-api-evolution.html)?
100
150
101
151
*TODO*
102
152
103
-
> ### What other unstable features may be exposed by this feature?
153
+
### Exposing other features
154
+
155
+
> Are there any other unstable features whose behavior may be exposed by this feature in any way? What features present the highest risk of that?
0 commit comments