Readd the matches_macro diag item

This is now used by Clippy
This commit is contained in:
Philipp Krones 2022-11-17 19:32:28 +01:00
parent b6097f2e1b
commit 34a14349b7
No known key found for this signature in database
GPG Key ID: 1CA0DF2AF59D68A5
2 changed files with 2 additions and 0 deletions

View File

@ -893,6 +893,7 @@
masked,
match_beginning_vert,
match_default_bindings,
matches_macro,
maxnumf32,
maxnumf64,
may_dangle,

View File

@ -338,6 +338,7 @@ macro_rules! debug_assert_ne {
/// ```
#[macro_export]
#[stable(feature = "matches_macro", since = "1.42.0")]
#[cfg_attr(not(test), rustc_diagnostic_item = "matches_macro")]
macro_rules! matches {
($expression:expr, $(|)? $( $pattern:pat_param )|+ $( if $guard: expr )? $(,)?) => {
match $expression {