@@ -578,25 +578,28 @@ pub fn check_crate(krate: &ast::Crate, sess: &Session, features: &Features) {
578
578
}
579
579
}
580
580
581
- // All uses of `gate_all !` below this point were added in #65742,
581
+ // All uses of `gate_all_legacy_dont_use !` below this point were added in #65742,
582
582
// and subsequently disabled (with the non-early gating readded).
583
583
// We emit an early future-incompatible warning for these.
584
584
// New syntax gates should go above here to get a hard error gate.
585
- macro_rules! gate_all {
585
+ macro_rules! gate_all_legacy_dont_use {
586
586
( $gate: ident, $msg: literal) => {
587
587
for span in spans. get( & sym:: $gate) . unwrap_or( & vec![ ] ) {
588
588
gate_feature_post!( future_incompatible; & visitor, $gate, * span, $msg) ;
589
589
}
590
590
} ;
591
591
}
592
592
593
- gate_all ! ( trait_alias, "trait aliases are experimental" ) ;
594
- gate_all ! ( associated_type_bounds, "associated type bounds are unstable" ) ;
595
- gate_all ! ( return_type_notation, "return type notation is experimental" ) ;
596
- gate_all ! ( decl_macro, "`macro` is experimental" ) ;
597
- gate_all ! ( box_patterns, "box pattern syntax is experimental" ) ;
598
- gate_all ! ( exclusive_range_pattern, "exclusive range pattern syntax is experimental" ) ;
599
- gate_all ! ( try_blocks, "`try` blocks are unstable" ) ;
593
+ gate_all_legacy_dont_use ! ( trait_alias, "trait aliases are experimental" ) ;
594
+ gate_all_legacy_dont_use ! ( associated_type_bounds, "associated type bounds are unstable" ) ;
595
+ gate_all_legacy_dont_use ! ( return_type_notation, "return type notation is experimental" ) ;
596
+ gate_all_legacy_dont_use ! ( decl_macro, "`macro` is experimental" ) ;
597
+ gate_all_legacy_dont_use ! ( box_patterns, "box pattern syntax is experimental" ) ;
598
+ gate_all_legacy_dont_use ! (
599
+ exclusive_range_pattern,
600
+ "exclusive range pattern syntax is experimental"
601
+ ) ;
602
+ gate_all_legacy_dont_use ! ( try_blocks, "`try` blocks are unstable" ) ;
600
603
601
604
visit:: walk_crate ( & mut visitor, krate) ;
602
605
}
0 commit comments