Skip to content

Commit f32afee

Browse files
committed
Document compiler flag sign-off guidance
1 parent 88e7405 commit f32afee

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/implementing-new-features.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -227,6 +227,7 @@ The below steps needs to be followed in order to implement a new unstable featur
227227
[here]: ./stabilization-guide.md
228228
[tracking issue]: #tracking-issues
229229
[add-feature-gate]: ./feature-gates.md#adding-a-feature-gate
230+
[guidance for compiler flags]: https://forge.rust-lang.org/compiler/proposals-and-stabilization.html?highlight=unstable%20flag#compiler-flags
230231

231232
## Adding unstable compiler flags
232233

@@ -235,6 +236,10 @@ controls, a `-Z` flag can be more appropriate than a language feature gate.
235236
Feature gates should still be preferred for user-facing language features,
236237
especially when crates need to opt in from source code.
237238

239+
Before adding a new flag, check the compiler team's [guidance for compiler flags].
240+
Some flags, especially those intended for direct nightly user workflows or broader
241+
ecosystem use, may need additional sign-off beyond an r+ on the implementation PR.
242+
238243
When adding a new `-Z` flag:
239244

240245
1. Add the option to `UnstableOptions` in

0 commit comments

Comments
 (0)