From 47e10664dce6d802206f2c2f178626705aae65c2 Mon Sep 17 00:00:00 2001 From: David Tolnay Date: Thu, 15 Jun 2023 18:53:17 -0700 Subject: [PATCH] Ignore uninlined_format_args pedantic clippy lint warning: variables can be used directly in the `format!` string --> benches/timer.rs:16:13 | 16 | let _ = writeln!(&mut writer, "{} in {} mode: {} micros", name, mode, micros); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args = note: `-W clippy::uninlined-format-args` implied by `-W clippy::pedantic` help: change this to | 16 - let _ = writeln!(&mut writer, "{} in {} mode: {} micros", name, mode, micros); 16 + let _ = writeln!(&mut writer, "{name} in {mode} mode: {micros} micros"); | --- benches/lib.rs | 6 +++++- benches/main.rs | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/benches/lib.rs b/benches/lib.rs index d11b771..d52f255 100644 --- a/benches/lib.rs +++ b/benches/lib.rs @@ -1,4 +1,8 @@ -#![allow(clippy::cast_lossless, clippy::let_underscore_untyped)] +#![allow( + clippy::cast_lossless, + clippy::let_underscore_untyped, + clippy::uninlined_format_args +)] use quote::quote; diff --git a/benches/main.rs b/benches/main.rs index 4ab5945..ba6fe77 100644 --- a/benches/main.rs +++ b/benches/main.rs @@ -1,5 +1,9 @@ #![allow(unknown_lints, special_module_name)] -#![allow(clippy::cast_lossless, clippy::let_underscore_untyped)] +#![allow( + clippy::cast_lossless, + clippy::let_underscore_untyped, + clippy::uninlined_format_args +)] quote_benchmark::run_quote_benchmark!(_);