Skip to content

Commit

Permalink
cargo-apk: Fix improved clippy::needless_borrow (rust-mobile#361)
Browse files Browse the repository at this point in the history
Rust 1.65 stepped up its `clippy::needless_borrow` game around types and
their borrows implementing a certain trait, realizing that `&PathBuf`
already implements `AsRef<Path>` and doesn't need to be reborrowed as
`&&PathBuf`.
  • Loading branch information
MarijnS95 authored Nov 5, 2022
1 parent b135fb1 commit 4c01bd2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cargo-apk/src/apk.rs
Original file line number Diff line number Diff line change
Expand Up @@ -151,17 +151,17 @@ impl<'a> ApkBuilder<'a> {
.manifest
.assets
.as_ref()
.map(|assets| dunce::simplified(&crate_path.join(&assets)).to_owned());
.map(|assets| dunce::simplified(&crate_path.join(assets)).to_owned());
let resources = self
.manifest
.resources
.as_ref()
.map(|res| dunce::simplified(&crate_path.join(&res)).to_owned());
.map(|res| dunce::simplified(&crate_path.join(res)).to_owned());
let runtime_libs = self
.manifest
.runtime_libs
.as_ref()
.map(|libs| dunce::simplified(&crate_path.join(&libs)).to_owned());
.map(|libs| dunce::simplified(&crate_path.join(libs)).to_owned());
let apk_name = self
.manifest
.apk_name
Expand Down

0 comments on commit 4c01bd2

Please sign in to comment.