From 928d332f83933f539526c6bfdf5266f45cb86a92 Mon Sep 17 00:00:00 2001 From: Daniel Hofstetter Date: Fri, 10 Jul 2026 09:28:18 +0200 Subject: [PATCH 1/2] clippy: fix useless_borrows_in_formatting lint https://rust-lang.github.io/rust-clippy/master/index.html#useless_borrows_in_formatting --- src/cmp.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cmp.rs b/src/cmp.rs index 0175466..6c3ab1c 100644 --- a/src/cmp.rs +++ b/src/cmp.rs @@ -706,8 +706,8 @@ fn report_difference( }; print!( "{} {} differ: {term} {}, line {}", - ¶ms.from.to_string_lossy(), - ¶ms.to.to_string_lossy(), + params.from.to_string_lossy(), + params.to.to_string_lossy(), at_byte, at_line ); From 1ece679d10f5a06d8908bacf721fe87ad3b89534 Mon Sep 17 00:00:00 2001 From: Daniel Hofstetter Date: Fri, 10 Jul 2026 09:30:42 +0200 Subject: [PATCH 2/2] clippy: fix byte_char_slices lint https://rust-lang.github.io/rust-clippy/master/index.html#byte_char_slices --- src/cmp.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cmp.rs b/src/cmp.rs index 6c3ab1c..e3534a0 100644 --- a/src/cmp.rs +++ b/src/cmp.rs @@ -477,7 +477,7 @@ pub fn main(opts: Peekable) -> ExitCode { #[inline] fn format_octal(byte: u8, buf: &mut [u8; 3]) -> &str { - *buf = [b' ', b' ', b'0']; + *buf = *b" 0"; let mut num = byte; let mut idx = 2; // Start at the last position in the buffer