Skip to content

Fix needless_range_loop for newer clippy - #8

Merged
Tomjerri1 merged 1 commit into
mainfrom
fix-clippy-newer
Nov 12, 2026
Merged

Tomjerri1 merged 1 commit into
mainfrom
fix-clippy-newer

Conversation

@Tomjerri1

@Tomjerri1 Tomjerri1 commented Nov 12, 2026 •

Copy link
Copy Markdown
Owner

Summary by CodeRabbit

  • Refactor
    • Updated internal snow calculations. Existing calculations and bounds remain unchanged, so snow behavior is unchanged for users. This release does not add or remove any user-facing features.

@coderabbitai

coderabbitai Bot commented Nov 12, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

Two loops in src/snow.rs now use iterators instead of indexing. The interpolation calculations, search bounds, and maximum-height comparison remain unchanged.

Changes: Snow height iteration

Layer / File(s) Summary
Update snow height iteration
src/snow.rs
seed_initial_piles updates heights through a mutable iterator. brush scans the selected height slice through an iterator. The calculations and bounds remain unchanged.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Change: Refactor

Merge Risk: Minimal · up to 7cb4e

This is a small refactor to satisfy a newer clippy lint, and the behavior is intended to stay the same. No actionable merge-blocking risk remains.

Pre-merge checks: Passed 4

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title names the lint and the change: it fixes the clippy needless_range_loop warning for newer clippy versions. The raw summary confirms the change matches this. In src/snow.rs, seed_initial_piles…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the lint and the change: it fixes the clippy needless_range_loop warning for newer clippy versions. The raw summary confirms the change matches this. In src/snow.rs, seed_initial_piles and brush now iterate over slices instead of indexing ranges, and the bounds and calculations stay the same. The title covers the main change.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: e67941fd-08f2-4ad3-b115-f98d9445400c
Commits

Reviewing files that changed from the base of the PR and between b4f151f and 7cb4e8d.

Files selected for processing: 1

  • src/snow.rs

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 8 remain after this review.

@Tomjerri1
Tomjerri1 merged commit 1f335ed into main Nov 12, 2026
3 checks passed
@Tomjerri1
Tomjerri1 deleted the fix-clippy-newer branch November 12, 2026 18:48
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