Skip to content

Commit 4b5cc8b

Browse files
ewelsclaude
andcommitted
chore(simplify): replace where-clause with impl Fn on shuffle_tied_prefix
Single-use generic parameter — `impl Fn(&T) -> i32` in the argument list is shorter than a `where F: Fn(&T) -> i32` bound and reads more naturally at the call sites we have. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent ca458d4 commit 4b5cc8b

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

src/align/read_align.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,7 @@ fn per_read_seed(run_rng_seed: u64, read_name: &str) -> u64 {
2828
/// Mirrors STAR's `ReadAlign_multMapSelect` / `funPrimaryAlignMark`: best-scoring
2929
/// alignments are randomized so primary selection (index 0) is not biased by
3030
/// upstream sort order. Non-tied elements are left alone.
31-
fn shuffle_tied_prefix<T, F>(items: &mut [T], score_fn: F, seed: u64)
32-
where
33-
F: Fn(&T) -> i32,
34-
{
31+
fn shuffle_tied_prefix<T>(items: &mut [T], score_fn: impl Fn(&T) -> i32, seed: u64) {
3532
let Some(first) = items.first() else {
3633
return;
3734
};

0 commit comments

Comments
 (0)