Skip to content

Comments

fix(clippy): resolve remaining sort_by and iter_without_into_iter warnings#554

Merged
echobt merged 1 commit intomasterfrom
fix/clippy-remaining-1770009149
Feb 2, 2026
Merged

fix(clippy): resolve remaining sort_by and iter_without_into_iter warnings#554
echobt merged 1 commit intomasterfrom
fix/clippy-remaining-1770009149

Conversation

@echobt
Copy link
Contributor

@echobt echobt commented Feb 2, 2026

Summary

Fixes the remaining Clippy warnings that were causing CI failures.

Changes

cortex-prompt-harness/src/builder.rs

  • Changed sort_by(|a, b| b.priority.cmp(&a.priority)) to sort_by_key(|s| std::cmp::Reverse(s.priority))

cortex-tui-framework/crates/cortex-tui-input/src/reader.rs

  • Added IntoIterator implementation for &InputReader to satisfy the iter_without_into_iter lint

Why

These changes address Clippy's unnecessary_sort_by and iter_without_into_iter lints which are configured as errors (-D warnings) in CI.

…nings

- cortex-prompt-harness/builder.rs: use sort_by_key with Reverse for priority sorting
- cortex-tui-input/reader.rs: add IntoIterator impl for &InputReader
@echobt echobt merged commit 60a4d8d 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