From fa4c5f2851fb8794c78e19518d9d484d042bab2c Mon Sep 17 00:00:00 2001 From: Kaspar Schleiser Date: Wed, 22 May 2024 13:31:12 +0200 Subject: [PATCH] fix new clippy warnings --- Cargo.toml | 2 +- src/data/import.rs | 2 +- src/nested_env/expand.rs | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index aa48729b..fe683f2d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,7 +10,7 @@ homepage = "https://laze-build.org" license = "Apache-2.0" readme = "README.md" include = ["src/**/*", "LICENSE", "README.md", "CHANGELOG.md", "!**/tests/**/*", "assets/**/*"] -rust-version = "1.64.0" # MSRV (clap needs recent Rust) +rust-version = "1.70.0" [dependencies] anyhow = "1.0.86" diff --git a/src/data/import.rs b/src/data/import.rs index 5d7bb2b7..7151e259 100644 --- a/src/data/import.rs +++ b/src/data/import.rs @@ -33,7 +33,7 @@ pub trait Import: std::hash::Hash { let mut res = Utf8PathBuf::from(build_dir.as_ref()); res.push("imports"); if let Some(dldir) = self.get_dldir() { - res.push(format!("{dldir}")); + res.push(dldir); } else if let Some(name) = self.get_name() { res.push(format!("{name}-{source_hash}")); } else { diff --git a/src/nested_env/expand.rs b/src/nested_env/expand.rs index 124ac8bd..9f933062 100644 --- a/src/nested_env/expand.rs +++ b/src/nested_env/expand.rs @@ -68,14 +68,14 @@ where .map_err(ExpandError::Expr))? } -fn expand_recursive<'a, SI: 'a, H>( +fn expand_recursive<'a, SI, H>( f: SI, r: &HashMap<&String, String, H>, seen: Vec<&'a str>, if_missing: IfMissing, ) -> Result where - SI: AsRef, + SI: 'a + AsRef, H: std::hash::BuildHasher, { let f = f.as_ref();