Skip to content

Commit

Permalink
Fix clippy lints from 1.83 beta (#3357)
Browse files Browse the repository at this point in the history
  • Loading branch information
luizirber authored Oct 17, 2024
1 parent 29b7887 commit 11cf59d
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 16 deletions.
18 changes: 9 additions & 9 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/core/src/ffi/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ impl From<String> for SourmashStr {
}
}

impl<'a> From<&'a str> for SourmashStr {
impl From<&str> for SourmashStr {
fn from(string: &str) -> SourmashStr {
SourmashStr::new(string)
}
Expand Down
3 changes: 1 addition & 2 deletions src/core/src/index/linear.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ use crate::storage::SigStore;
use crate::Result;

/// Supports parallel search without a particular index.
pub struct LinearIndex {
collection: CollectionSet,
template: Sketch,
Expand Down Expand Up @@ -313,7 +312,7 @@ impl Select for LinearIndex {
}
}

impl<'a> Index<'a> for LinearIndex {
impl Index<'_> for LinearIndex {
type Item = SigStore;

fn insert(&mut self, _node: Self::Item) -> Result<()> {
Expand Down
2 changes: 1 addition & 1 deletion src/core/src/index/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ pub trait Index<'a> {
*/
}

impl<'a, N, L> Comparable<L> for &'a N
impl<N, L> Comparable<L> for &N
where
N: Comparable<L>,
{
Expand Down
2 changes: 1 addition & 1 deletion src/core/src/index/revindex/disk_revindex.rs
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ impl RevIndexOps for RevIndex {
// grab the specific intersection:
// Calculate stats
let (gather_result, isect) = calculate_gather_stats(
&orig_query,
orig_query,
query_mh,
match_sig,
match_size,
Expand Down
2 changes: 1 addition & 1 deletion src/core/src/index/revindex/mem_revindex.rs
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ impl RevIndex {
}
}

impl<'a> Index<'a> for RevIndex {
impl Index<'_> for RevIndex {
type Item = Signature;

fn insert(&mut self, _node: Self::Item) -> Result<()> {
Expand Down
2 changes: 1 addition & 1 deletion src/core/src/signature.rs
Original file line number Diff line number Diff line change
Expand Up @@ -902,7 +902,7 @@ impl TryInto<KmerMinHash> for Signature {
None
}
})
.ok_or_else(|| Error::NoMinHashFound),
.ok_or(Error::NoMinHashFound),
0 => Err(Error::EmptySignature),
_ => Err(Error::MultipleSketchesFound),
}
Expand Down

0 comments on commit 11cf59d

Please sign in to comment.