From 20cef7159dc02ae460082ebf9144fb1499e18480 Mon Sep 17 00:00:00 2001 From: Michael Kefeder Date: Fri, 7 Jun 2024 21:37:39 +0200 Subject: [PATCH] make recent clippy happy --- Cargo.toml | 5 ----- lcov2cobertura/src/lib.rs | 2 ++ 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 2621a6b..1d16599 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -62,11 +62,6 @@ rust-2018-idioms = "deny" nonstandard-style = "deny" [lints.clippy] -unwrap_used = "deny" -unwrap_in_result = "deny" -panic = "deny" -expect_used = "deny" -unimplemented = "deny" suspicious = "forbid" style = "forbid" complexity = "forbid" diff --git a/lcov2cobertura/src/lib.rs b/lcov2cobertura/src/lib.rs index 7b0bbc9..3352c6b 100644 --- a/lcov2cobertura/src/lib.rs +++ b/lcov2cobertura/src/lib.rs @@ -326,6 +326,8 @@ pub fn parse_lines, B: BufRead>( let mut split = line.splitn(2, ':'); let (input_type, line) = (split.next(), split.last()); + // proposed improvement only works in rustc 1.63 and above + #[allow(clippy::assigning_clones)] match input_type { Some("SF") => { let file_name = line.ok_or_else(|| anyhow::anyhow!("SF entry has no filename"))?;