File tree Expand file tree Collapse file tree 2 files changed +17
-3
lines changed
compiler/rustc_lint_defs/src
src/doc/rustc/src/lints/listing Expand file tree Collapse file tree 2 files changed +17
-3
lines changed Original file line number Diff line number Diff line change @@ -1228,6 +1228,22 @@ declare_lint! {
12281228 } ;
12291229}
12301230
1231+ declare_lint ! {
1232+ /// The missing_fragment_specifier warning is issued when an unused pattern in a
1233+ /// `macro_rules!` macro definition has a meta-variable (e.g. `$e`) that is not
1234+ /// followed by a fragment specifier (e.g. `:expr`).
1235+ ///
1236+ /// This warning can always be fixed by removing the unused pattern in the
1237+ /// `macro_rules!` macro definition.
1238+ pub MISSING_FRAGMENT_SPECIFIER ,
1239+ Deny ,
1240+ "detects missing fragment specifiers in unused `macro_rules!` patterns" ,
1241+ @future_incompatible = FutureIncompatibleInfo {
1242+ reference: "issue #40107 <https://github.com/rust-lang/rust/issues/40107>" ,
1243+ edition: None ,
1244+ } ;
1245+ }
1246+
12311247declare_lint ! {
12321248 /// The `late_bound_lifetime_arguments` lint detects generic lifetime
12331249 /// arguments in path segments with late bound lifetime parameters.
@@ -2784,6 +2800,7 @@ declare_lint_pass! {
27842800 CONST_ITEM_MUTATION ,
27852801 SAFE_PACKED_BORROWS ,
27862802 PATTERNS_IN_FNS_WITHOUT_BODY ,
2803+ MISSING_FRAGMENT_SPECIFIER ,
27872804 LATE_BOUND_LIFETIME_ARGUMENTS ,
27882805 ORDER_DEPENDENT_TRAIT_OBJECTS ,
27892806 COHERENCE_LEAK_CHECK ,
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments