Skip to content

Add unused_impl lint#16762

Open
vogelbirb wants to merge 1 commit intorust-lang:masterfrom
vogelbirb:unused_impl
Open

Add unused_impl lint#16762
vogelbirb wants to merge 1 commit intorust-lang:masterfrom
vogelbirb:unused_impl

Conversation

@vogelbirb
Copy link
Copy Markdown
Contributor

@vogelbirb vogelbirb commented Mar 26, 2026

Added exceptions (mostly #![allow(clippy::unused_impl)]) to the following lints:

  • impl
  • into_iter_without_iter
  • mismatching_type_param_order
  • multiple_inherent_impl_cfg
  • needless_lifetimes
  • needless_maybe_sized
  • too_long_first_doc_paragraph
  • doc_comments
  • unknown_clippy_lints
    • Suggestion changed to clippy::unused_impl from clippy::unused_self

fixes #16758
changelog: new lint: [unused_impl]

@rustbot rustbot added needs-fcp PRs that add, remove, or rename lints and need an FCP S-waiting-on-review Status: Awaiting review from the assignee but also interested parties labels Mar 26, 2026
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Mar 26, 2026

r? @samueltardieu

rustbot has assigned @samueltardieu.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: 7 candidates
  • 7 candidates expanded to 7 candidates
  • Random selection from Jarcho, dswij, llogiq, samueltardieu

@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 26, 2026

Lintcheck changes for 612b2b0

Lint Added Removed Changed
clippy::unused_impl 13 0 0

This comment will be updated if you push new changes

@vogelbirb vogelbirb changed the title feat: add unused_impl lint Add unused_impl lint Mar 26, 2026
Copy link
Copy Markdown
Member

@samueltardieu samueltardieu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lintcheck shows false positives. An empty impl block with comments or #[cfg] should not be linted.

Please write a meaningful PR message, the current one looks like LLM verbose output.

When the .fixed file of an unrelated test still triggers the lint, use #![expect] instead of #![allow].

View changes since this review

@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action from the author. (Use `@rustbot ready` to update this status) and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties labels Mar 27, 2026
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Mar 27, 2026

Reminder, once the PR becomes ready for a review, use @rustbot ready.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-fcp PRs that add, remove, or rename lints and need an FCP S-waiting-on-author Status: This is awaiting some action from the author. (Use `@rustbot ready` to update this status)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Suggest to remove empty impl body

3 participants