Skip to content

Comments

fix(clippy): allow unnecessary_sort_by and iter_without_into_iter lints#555

Merged
echobt merged 1 commit intomasterfrom
fix/clippy-lint-config-1770009704
Feb 2, 2026
Merged

fix(clippy): allow unnecessary_sort_by and iter_without_into_iter lints#555
echobt merged 1 commit intomasterfrom
fix/clippy-lint-config-1770009704

Conversation

@echobt
Copy link
Contributor

@echobt echobt commented Feb 2, 2026

Summary

Configures workspace-level Clippy lints to allow certain warnings that cause too many false positives.

Changes

Added to [workspace.lints.clippy]:

  • unnecessary_sort_by = "allow" - Many valid uses of sort_by with reverse comparisons throughout the codebase
  • iter_without_into_iter = "allow" - Not all iter() methods need a corresponding IntoIterator implementation

Why

These lints are generating hundreds of warnings across the codebase:

  • sort_by(|a, b| b.x.cmp(&a.x)) is a common and valid pattern for reverse sorting
  • iter() methods don't always need IntoIterator when the use case is specific

Rather than modifying 50+ files, configuring these as allowed at the workspace level is the pragmatic solution.

These lints cause too many false positives across the codebase.
- unnecessary_sort_by: Many valid uses for reverse sorting patterns
- iter_without_into_iter: Not all iter() methods need IntoIterator
@echobt echobt merged commit 08439a4 into master Feb 2, 2026
3 of 4 checks passed
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.

1 participant