Skip to content

Commit 0c9a1cd

Browse files
committed
Add run-make test print-in-stable-or-unstable-channel
Signed-off-by: xizheyin <[email protected]>
1 parent 0df1c83 commit 0c9a1cd

File tree

7 files changed

+465
-3
lines changed

7 files changed

+465
-3
lines changed

compiler/rustc_session/src/config.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -2094,15 +2094,15 @@ fn check_print_request_stability(
20942094
unstable_opts: &UnstableOptions,
20952095
(print_name, print_kind): (&str, PrintKind),
20962096
) {
2097-
if !is_print_request_stability(print_kind) && !unstable_opts.unstable_options {
2097+
if !is_print_request_stable(print_kind) && !unstable_opts.unstable_options {
20982098
early_dcx.early_fatal(format!(
20992099
"the `-Z unstable-options` flag must also be passed to enable the `{print_name}` \
21002100
print option"
21012101
));
21022102
}
21032103
}
21042104

2105-
fn is_print_request_stability(print_kind: PrintKind) -> bool {
2105+
fn is_print_request_stable(print_kind: PrintKind) -> bool {
21062106
match print_kind {
21072107
PrintKind::AllTargetSpecsJson
21082108
| PrintKind::CheckCfg
@@ -2118,7 +2118,7 @@ fn emit_unknown_print_request_help(early_dcx: &EarlyDiagCtxt, req: &str, is_nigh
21182118
.iter()
21192119
.filter_map(|(name, kind)| {
21202120
// If we're not on nightly, we don't want to print unstable options
2121-
if !is_nightly && !is_print_request_stability(*kind) {
2121+
if !is_nightly && !is_print_request_stable(*kind) {
21222122
None
21232123
} else {
21242124
Some(format!("`{name}`"))

0 commit comments

Comments
 (0)