Fix clippy lint
#[warn(clippy:match_like_matches_macro)]
@@ -29,10 +29,7 @@ pub fn global_logger(args: TokenStream, input: TokenStream) -> TokenStream {
}
let s = parse_macro_input!(input as ItemStruct);
let ident = &s.ident;
- let is_unit = match s.fields {
- Fields::Unit => true,
- _ => false,
- };
+ let is_unit = matches!(s.fields, Fields::Unit);
if !s.generics.params.is_empty() || s.generics.where_clause.is_some() || !is_unit {
return parse::Error::new(
ident.span(),
