rust-lang / rust-lang/rust-clippy

Suggest _[x..][..n] instead of _[x..x+n]

Open
#2,272 9 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

L-suggestion
Dominant language
Rust
Stars
13.5k
Forks
2.2k
Avg merge
2d 10h
Merged PRs (30d)
32

Description

This may well be an allowed lint, but I think the latter way is cool and want more folks to learn about it 🙂

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file, test, or entry point is named. Start by locating the Clippy lint handling the _ [x..x+n] pattern, then inspect its existing diagnostics and tests; done means the preferred _[x..][..n] form is suggested and the relevant lint behavior is covered.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
tooling
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.