about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAlex Macleod <alex@macleod.io>2022-07-31 15:11:00 +0000
committerAlex Macleod <alex@macleod.io>2022-07-31 15:11:33 +0000
commitcd135749920d85596bc539ce393d02698b49429f (patch)
tree4344e5eea1fc4d528d9872f7a927552db47ceed5
parent3641b0ca300065f22cdb96007f351a228a8bad5f (diff)
downloadrust-cd135749920d85596bc539ce393d02698b49429f.tar.gz
rust-cd135749920d85596bc539ce393d02698b49429f.zip
Always include a position span in rustc_parse_format::Argument
-rw-r--r--clippy_lints/src/write.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/clippy_lints/src/write.rs b/clippy_lints/src/write.rs
index 3a99d1b417f..32718200c0b 100644
--- a/clippy_lints/src/write.rs
+++ b/clippy_lints/src/write.rs
@@ -441,7 +441,7 @@ impl SimpleFormatArgs {
         };
 
         match arg.position {
-            ArgumentIs(n, _) | ArgumentImplicitlyIs(n) => {
+            ArgumentIs(n) | ArgumentImplicitlyIs(n) => {
                 if self.unnamed.len() <= n {
                     // Use a dummy span to mark all unseen arguments.
                     self.unnamed.resize_with(n, || vec![DUMMY_SP]);
@@ -462,7 +462,7 @@ impl SimpleFormatArgs {
                     }
                 }
             },
-            ArgumentNamed(n, _) => {
+            ArgumentNamed(n) => {
                 let n = Symbol::intern(n);
                 if let Some(x) = self.named.iter_mut().find(|x| x.0 == n) {
                     match x.1.as_slice() {