Skip to content

Commit

Permalink
Fix Clippy warnings
Browse files Browse the repository at this point in the history
- clippy 0.1.77 (f2048098a1c 2024-02-09)
- Remove `actions-rs/clippy-check` GH action.
  • Loading branch information
tatsuya6502 committed Feb 12, 2024
1 parent 5bbd16b commit 79c6390
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
5 changes: 1 addition & 4 deletions .github/workflows/Lints.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,7 @@ jobs:
- run: cargo clean

- name: Run Clippy
uses: actions-rs/clippy-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: --lib --tests --all-features --all-targets -- -D warnings
run: cargo clippy --lib --tests --all-features --all-targets -- -D warnings
env:
RUSTFLAGS: ${{ matrix.rust.rustflags }}

Expand Down
2 changes: 1 addition & 1 deletion src/sync/base_cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ impl<K, V, S> Clone for BaseCache<K, V, S> {
inner: Arc::clone(&self.inner),
read_op_ch: self.read_op_ch.clone(),
write_op_ch: self.write_op_ch.clone(),
housekeeper: self.housekeeper.as_ref().map(Arc::clone),
housekeeper: self.housekeeper.clone(),
}
}
}
Expand Down
3 changes: 3 additions & 0 deletions src/unsync/cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -956,6 +956,9 @@ where
break;
}

// clippy::map_clone will give us a false positive warning here.
// Version: clippy 0.1.77 (f2048098a1c 2024-02-09) in Rust 1.77.0-beta.2
#[allow(clippy::map_clone)]
let key = probation
.peek_front()
.map(|node| Rc::clone(&node.element.key));
Expand Down

0 comments on commit 79c6390

Please sign in to comment.