Skip to content

chore: fix clippy warnings from Rust 1.98 - #157

Merged
mrvollger merged 1 commit into
mainfrom
chore/clippy
Nov 5, 2026
Merged

mrvollger merged 1 commit into
mainfrom
chore/clippy

Conversation

@mrvollger

Copy link
Copy Markdown
Member

Rust 1.98 stable clippy reports 22 warnings on main. None of them fail CI, but they hide new warnings in local runs.

  • Replace late let initialization with a tuple from if/else (fiber.rs).
  • Use ? in place of a match that returns None (fiber.rs).
  • Remove redundant references and .into_iter() calls, and use a byte string (center.rs, qc.rs, predict_m6a.rs, tests).
  • Reword a doc comment whose >= lines rustdoc read as block quotes (ma_io.rs).
  • Build FiberFilters with struct update syntax in tests (tests/input_bam.rs).

No behavior change. cargo clippy --all-targets is clean and all 156 tests pass.

Newer stable clippy flags 22 warnings across the lib and tests. CI does
not fail on them yet, but they hide new warnings in local runs. No
behavior change.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The Clippy-warning cleanup has no active review issues.

No open issues 🎉

What changed in this PR

This PR cleans up Clippy warnings across fiber processing code and tests, with no intended behavior changes.

Changes:

  • Simplify initialization and optional-value handling in fiber.rs.
  • Remove redundant iterator conversions, references, imports, and test setup patterns.
  • Reword callable-span documentation to avoid unintended rustdoc formatting.
File Description
tests/​regression/​qc.rs Remove an unnecessary explicit lifetime.
tests/​molecular_annotation.rs Use to_vec() to clone a slice.
tests/​input_bam.rs Initialize filters with struct update syntax.
tests/​fibertig_test.rs Remove a redundant .into_iter() call.
tests/​fiber_stream.rs Remove an unused trait import.
src/​utils/​ma_io.rs Reword documentation to avoid block-quote formatting.
src/​subcommands/​qc.rs Remove a redundant .into_iter() call.
src/​subcommands/​predict_m6a.rs Iterate over a byte string for DNA bases.
src/​subcommands/​center.rs Remove a redundant reference in formatting.
src/​fiber.rs Use tuple initialization and ? for optional chunk handling.

Review effort: Balanced

@mrvollger
mrvollger merged commit 4a83ec8 into main Nov 5, 2026
10 checks passed
@github-actions github-actions Bot mentioned this pull request Nov 5, 2026
@mrvollger
mrvollger deleted the chore/clippy branch November 5, 2026 22:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants