Skip to content

fix(list): satisfy clippy's needless_range_loop on Rust 1.100 - #33

Merged
ChmaraX merged 1 commit into
mainfrom
fix/clippy-needless-range-loop
Nov 14, 2026
Merged

ChmaraX merged 1 commit into
mainfrom
fix/clippy-needless-range-loop

Conversation

@ChmaraX

@ChmaraX ChmaraX commented Nov 14, 2026

Copy link
Copy Markdown
Owner

Problem

CI installs the latest stable Rust. Rust 1.100's clippy added needless_range_loop for row_at in src/list/app.rs, so cargo clippy --all-targets -- -D warnings now fails on main, and every open PR's test job fails on that line, even PRs that don't touch it (#28, #29, #30, #31, #32).

Fix

row_at iterates the rows directly (iter().enumerate().skip(list_offset)) instead of indexing. Same behavior: an offset past the end still yields no row.

Proof

On Rust 1.100.0: cargo fmt --check, cargo clippy --all-targets -- -D warnings and cargo test pass on this branch. They also pass on each of #28–#32 with this commit merged in.

@ChmaraX
ChmaraX merged commit 675fb3d into main Nov 14, 2026
2 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