From 2af642da28109c96145c7a5613ae2ec37d359448 Mon Sep 17 00:00:00 2001 From: pro-grammer1 <1df0d0d3-eed4-45fc-bc60-43a85079f3f9@anonaddy.me> Date: Sun, 17 Jan 2021 18:01:01 +0000 Subject: [PATCH] Replace another instance of match with matches --- clippy_lints/src/write.rs | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/clippy_lints/src/write.rs b/clippy_lints/src/write.rs index 52118a56bb6..6721639f724 100644 --- a/clippy_lints/src/write.rs +++ b/clippy_lints/src/write.rs @@ -443,12 +443,7 @@ impl Write { return (Some(fmtstr), None); }; match &token_expr.kind { - ExprKind::Lit(lit) - if match lit.kind { - LitKind::Int(_, _) | LitKind::Float(_, _) => false, - _ => true, - } => - { + ExprKind::Lit(lit) if matches!(lit.kind, LitKind::Int(..) | LitKind::Float(..)) => { let mut all_simple = true; let mut seen = false; for arg in &args {