Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix clippy::needless_borrows_for_generic_args lints #353

Merged
merged 1 commit into from
Jul 25, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ mod tests {

fn file_name(name: &str, prefix: &str, suffix: &str) -> String {
let container: HashSet<String> = HashSet::new();
user_name_to_file_name(&Name::new_raw(name), prefix, suffix, |name| {
user_name_to_file_name(Name::new_raw(name), prefix, suffix, |name| {
!container.contains(name)
})
.to_string_lossy()
Expand Down Expand Up @@ -292,7 +292,7 @@ mod tests {
let mut container = HashSet::new();
let mut existing = HashSet::new();
for name in ["Ab", "a_b"] {
let path = user_name_to_file_name(&Name::new_raw(name), "", ".glif", |name| {
let path = user_name_to_file_name(Name::new_raw(name), "", ".glif", |name| {
!existing.contains(name)
});
existing.insert(path.to_string_lossy().to_string().to_lowercase());
Expand All @@ -311,7 +311,7 @@ mod tests {
let mut container = HashSet::new();
let mut existing = HashSet::new();
for name in ["A".repeat(300), "a_".repeat(150)] {
let path = user_name_to_file_name(&Name::new_raw(&name), "", ".glif", |name| {
let path = user_name_to_file_name(Name::new_raw(&name), "", ".glif", |name| {
!existing.contains(name)
});
existing.insert(path.to_string_lossy().to_string().to_lowercase());
Expand Down