Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a new lint: deref coercions #14059

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open

Conversation

yegeunyang
Copy link

@yegeunyang yegeunyang commented Jan 22, 2025

Hi, I added a new lint deref coercions to resolve #7104.
This is my first time contributing to clippy, so please leave me some feedbacks!


changelog: [deref_coercions]: new lint

@rustbot
Copy link
Collaborator

rustbot commented Jan 22, 2025

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @Jarcho (or someone else) some time within the next two weeks.

Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (S-waiting-on-review and S-waiting-on-author) stays updated, invoking these commands when appropriate:

  • @rustbot author: the review is finished, PR author should check the comments and take action accordingly
  • @rustbot review: the author is ready for a review, this PR will be queued again in the reviewer's queue

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties label Jan 22, 2025
@yegeunyang yegeunyang changed the title [WIP] Add deref coercions lint #7104 [WIP] Add a new lint: deref coercions Jan 22, 2025
@yegeunyang yegeunyang changed the title [WIP] Add a new lint: deref coercions Add a new lint: deref coercions Jan 26, 2025
@samueltardieu
Copy link
Contributor

Out of curiosity, do you know of any project or style guide which forbids deref coercions in its codebase?

@yegeunyang
Copy link
Author

yegeunyang commented Jan 28, 2025

Out of curiosity, do you know of any project or style guide which forbids deref coercions in its codebase?

I don't know. I love using deref coercions, but I hope this one might be useful to some people... Because, over the years, I've seen some people who dislike it.

@samueltardieu
Copy link
Contributor

I am asking because to me it looks like a lint which enforces a non-existing practice, and for which there is no demand. If I was the one deciding whether to accept it or not, I would seriously weight this against the additional maintenance burden, and probably reject it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties
Projects
None yet
Development

Successfully merging this pull request may close these issues.

New lint: deref coercions
5 participants